Class SpringWebObjectFactory

  • All Implemented Interfaces:
    org.atmosphere.cpr.AtmosphereObjectFactory<java.lang.Class<?>>, org.atmosphere.inject.AtmosphereConfigAware

    public class SpringWebObjectFactory
    extends java.lang.Object
    implements org.atmosphere.cpr.AtmosphereObjectFactory<java.lang.Class<?>>
    An AtmosphereObjectFactory for Spring to be used in Servlet Base Java Apps.
    Author:
    Aparup Banerjee
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String ATMOSPHERE_SPRING_EXCLUDE_CLASSES
      A comma delimited list of org.atmosphere.inject.InjectableObjectFactory.DEFAULT_ATMOSPHERE_INJECTABLE that won't be created by Spring.
      protected boolean preventSpringInjection  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      org.atmosphere.cpr.AtmosphereObjectFactory allowInjectionOf​(java.lang.Class<?> aClass)  
      void configure​(org.atmosphere.cpr.AtmosphereConfig config)  
      <T,​U extends T>
      U
      newClassInstance​(java.lang.Class<T> classType, java.lang.Class<U> classToInstantiate)  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • ATMOSPHERE_SPRING_EXCLUDE_CLASSES

        public static final java.lang.String ATMOSPHERE_SPRING_EXCLUDE_CLASSES
        A comma delimited list of org.atmosphere.inject.InjectableObjectFactory.DEFAULT_ATMOSPHERE_INJECTABLE that won't be created by Spring.
        See Also:
        Constant Field Values
      • preventSpringInjection

        protected boolean preventSpringInjection
    • Constructor Detail

      • SpringWebObjectFactory

        public SpringWebObjectFactory()
    • Method Detail

      • newClassInstance

        public <T,​U extends T> U newClassInstance​(java.lang.Class<T> classType,
                                                        java.lang.Class<U> classToInstantiate)
                                                 throws java.lang.InstantiationException,
                                                        java.lang.IllegalAccessException
        Specified by:
        newClassInstance in interface org.atmosphere.cpr.AtmosphereObjectFactory<java.lang.Class<?>>
        Throws:
        java.lang.InstantiationException
        java.lang.IllegalAccessException
      • allowInjectionOf

        public org.atmosphere.cpr.AtmosphereObjectFactory allowInjectionOf​(java.lang.Class<?> aClass)
        Specified by:
        allowInjectionOf in interface org.atmosphere.cpr.AtmosphereObjectFactory<java.lang.Class<?>>
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • configure

        public void configure​(org.atmosphere.cpr.AtmosphereConfig config)
        Specified by:
        configure in interface org.atmosphere.inject.AtmosphereConfigAware