Skip navigation links
com.caucho.config.inject

Class AbstractSingletonBean<T>

    • Method Detail

      • getQualifiers

        public java.util.Set<java.lang.annotation.Annotation> getQualifiers()
        Description copied from interface: Bean
        Returns the bean's qualifier annotations.
        Specified by:
        getQualifiers in interface Bean<T>
        Overrides:
        getQualifiers in class BeanAdapter<T,T>
      • getStereotypes

        public java.util.Set<java.lang.Class<? extends java.lang.annotation.Annotation>> getStereotypes()
        Description copied from interface: Bean
        Returns the stereotypes that the bean uses for priority
        Specified by:
        getStereotypes in interface Bean<T>
        Overrides:
        getStereotypes in class BeanAdapter<T,T>
      • getName

        public java.lang.String getName()
        Description copied from interface: Bean
        Returns the bean's name or null if the bean does not have a primary name.
        Specified by:
        getName in interface Bean<T>
        Overrides:
        getName in class BeanAdapter<T,T>
      • introspectProduces

        public void introspectProduces()
      • introspectObservers

        public void introspectObservers()
      • getScope

        public java.lang.Class<? extends java.lang.annotation.Annotation> getScope()
        Returns the bean's scope type.
        Specified by:
        getScope in interface Bean<T>
        Overrides:
        getScope in class BeanAdapter<T,T>
      • getTypes

        public java.util.Set<java.lang.reflect.Type> getTypes()
        Returns the types that the bean exports for bindings.
        Specified by:
        getTypes in interface Bean<T>
        Overrides:
        getTypes in class BeanAdapter<T,T>
      • create

        public abstract T create(CreationalContext<T> env)
        Description copied from interface: Contextual
        Creates a new instance for the Contextual's type. If the instance already exists in the CreationalContext, create will return it instead of creating a new instance.
        1. create an instance of the bean
        2. create interceptor and decorator stacks
        3. inject dependencies
        4. set any XML-configured values
        5. call @PostConstruct
        Specified by:
        create in interface Contextual<T>
        Overrides:
        create in class BeanWrapper<T>
        Parameters:
        env - the creation context used to support circular references.
        Returns:
        the new instance
      • close

        public void close()
        Frees the singleton on environment shutdown
        Specified by:
        close in interface java.io.Closeable
        Specified by:
        close in interface java.lang.AutoCloseable