SourceForge.net Logo

org.springframework.web.jsf
Class FacesBeanDefinition

java.lang.Object
  extended byorg.springframework.beans.factory.support.AbstractBeanDefinition
      extended byorg.springframework.beans.factory.support.RootBeanDefinition
          extended byorg.springframework.web.jsf.FacesBeanDefinition
All Implemented Interfaces:
BeanDefinition

public class FacesBeanDefinition
extends RootBeanDefinition

RootBeanDefinition for beans defined in a JSF context.

JSF does not support

Thus, methods inherited from RootBeanDefinition which enable these features will throw an UnsupportedOperationException.

Author:
Andreas Kuhrwahl, Thomas Jachmann
See Also:
VariableResolverImpl, AutowireCapableBeanFactory

Field Summary
static java.lang.String APPLICATION_SCOPE
           
static java.lang.String NONE_SCOPE
           
static java.lang.String REQUEST_SCOPE
           
static java.lang.String SESSION_SCOPE
           
 
Fields inherited from class org.springframework.beans.factory.support.RootBeanDefinition
AUTOWIRE_AUTODETECT, AUTOWIRE_BY_NAME, AUTOWIRE_BY_TYPE, AUTOWIRE_CONSTRUCTOR, AUTOWIRE_NO, DEPENDENCY_CHECK_ALL, DEPENDENCY_CHECK_NONE, DEPENDENCY_CHECK_OBJECTS, DEPENDENCY_CHECK_SIMPLE
 
Constructor Summary
FacesBeanDefinition(java.lang.Class beanClass, MutablePropertyValues pvs, java.lang.String scope)
          Create a new FacesBeanDefinition for a singleton, providing property values.
FacesBeanDefinition(java.lang.String beanClassName, MutablePropertyValues pvs, java.lang.String scope)
          Create a new FacesBeanDefinition for a singleton, providing property values.
 
Method Summary
 int getResolvedAutowireMode()
          Returns AUTOWIRE_NO since JSF does not support autowiring.
 boolean hasConstructorArgumentValues()
          Always returns false since beans defined in a JSF context have no constructor arguments.
 boolean isApplicationScope()
          Returns wether the faces bean-defintion has application-scope or not.
 boolean isRequestScope()
          Returns wether the faces bean-defintion has request-scope or not.
 boolean isSessionScope()
          Returns wether the faces bean-defintion has session-scope or not.
 void setAutowireMode(int autowireMode)
          Not supported by this implementation.
 void setDependencyCheck(int dependencyCheck)
          Not supported by this implementation.
 void setDependsOn(java.lang.String[] dependsOn)
          Not supported by this implementation.
 void setDestroyMethodName(java.lang.String destroyMethodName)
          Not supported by this implementation.
 void setInitMethodName(java.lang.String initMethodName)
          Not supported by this implementation.
 void setLazyInit(boolean lazyInit)
          Not supported by this implementation.
 void validate()
          The JSF implementation used will validate bean definitions, so this implementation does nothing.
 
Methods inherited from class org.springframework.beans.factory.support.RootBeanDefinition
getAutowireMode, getBeanClass, getBeanClassName, getConstructorArgumentValues, getDependencyCheck, getDependsOn, getDestroyMethodName, getInitMethodName, toString
 
Methods inherited from class org.springframework.beans.factory.support.AbstractBeanDefinition
getPropertyValues, getResourceDescription, isLazyInit, isSingleton, setResourceDescription, setSingleton
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

APPLICATION_SCOPE

public static final java.lang.String APPLICATION_SCOPE
See Also:
Constant Field Values

SESSION_SCOPE

public static final java.lang.String SESSION_SCOPE
See Also:
Constant Field Values

REQUEST_SCOPE

public static final java.lang.String REQUEST_SCOPE
See Also:
Constant Field Values

NONE_SCOPE

public static final java.lang.String NONE_SCOPE
See Also:
Constant Field Values
Constructor Detail

FacesBeanDefinition

public FacesBeanDefinition(java.lang.Class beanClass,
                           MutablePropertyValues pvs,
                           java.lang.String scope)
Create a new FacesBeanDefinition for a singleton, providing property values.

Parameters:
beanClass - the class of the bean to instantiate
pvs - the property values to apply

FacesBeanDefinition

public FacesBeanDefinition(java.lang.String beanClassName,
                           MutablePropertyValues pvs,
                           java.lang.String scope)
Create a new FacesBeanDefinition for a singleton, providing property values. Takes a bean class name to avoid eager loading of the bean class.

Parameters:
beanClassName - the name of the class to instantiate
pvs - the property values to apply
Method Detail

setAutowireMode

public void setAutowireMode(int autowireMode)
Not supported by this implementation.

Throws:
java.lang.UnsupportedOperationException
See Also:
RootBeanDefinition.setAutowireMode(int)

setDependencyCheck

public void setDependencyCheck(int dependencyCheck)
Not supported by this implementation.

Throws:
java.lang.UnsupportedOperationException
See Also:
RootBeanDefinition.setDependencyCheck(int)

setDependsOn

public void setDependsOn(java.lang.String[] dependsOn)
Not supported by this implementation.

Throws:
java.lang.UnsupportedOperationException
See Also:
RootBeanDefinition.setDependsOn(java.lang.String[])

setDestroyMethodName

public void setDestroyMethodName(java.lang.String destroyMethodName)
Not supported by this implementation.

Throws:
java.lang.UnsupportedOperationException
See Also:
RootBeanDefinition.setDestroyMethodName(java.lang.String)

setInitMethodName

public void setInitMethodName(java.lang.String initMethodName)
Not supported by this implementation.

Throws:
java.lang.UnsupportedOperationException
See Also:
RootBeanDefinition.setInitMethodName(java.lang.String)

setLazyInit

public void setLazyInit(boolean lazyInit)
Not supported by this implementation.

Throws:
java.lang.UnsupportedOperationException
See Also:
AbstractBeanDefinition.setLazyInit(boolean)

hasConstructorArgumentValues

public boolean hasConstructorArgumentValues()
Always returns false since beans defined in a JSF context have no constructor arguments.

See Also:
RootBeanDefinition.hasConstructorArgumentValues()

validate

public void validate()
              throws BeanDefinitionValidationException
The JSF implementation used will validate bean definitions, so this implementation does nothing.

Throws:
BeanDefinitionValidationException
See Also:
AbstractBeanDefinition.validate()

getResolvedAutowireMode

public int getResolvedAutowireMode()
Returns AUTOWIRE_NO since JSF does not support autowiring.

See Also:
RootBeanDefinition.getResolvedAutowireMode()

isApplicationScope

public boolean isApplicationScope()
Returns wether the faces bean-defintion has application-scope or not.


isRequestScope

public boolean isRequestScope()
Returns wether the faces bean-defintion has request-scope or not.


isSessionScope

public boolean isSessionScope()
Returns wether the faces bean-defintion has session-scope or not.


SourceForge.net Logo