com.interface21.beans.factory.support
Class AbstractBeanDefinition

java.lang.Object
  |
  +--com.interface21.beans.factory.support.AbstractBeanDefinition
Direct Known Subclasses:
ChildBeanDefinition, RootBeanDefinition

public abstract class AbstractBeanDefinition
extends java.lang.Object

Internal BeanFactory implementation class. This abstract base class defines the BeanFactory type.Use a FactoryBean to customize behaviour when returning application beans.

A BeanDefinition describes a bean instance, which has property values and further information supplied by concrete classes or subinterfaces.

Once configuration is complete, a BeanFactory will be able to return direct references to objects defined by BeanDefinitions.

Version:
$Revision: 1.6 $
Author:
Rod Johnson

Constructor Summary
protected AbstractBeanDefinition()
           
protected AbstractBeanDefinition(PropertyValues pvs, boolean singleton)
          Creates new BeanDefinition
 
Method Summary
 boolean equals(java.lang.Object other)
           
 PropertyValues getPropertyValues()
          Return the PropertyValues to be applied to a new instance of this bean.
 boolean isSingleton()
          Is this a Singleton, with a single, shared instance returned on all calls, or should the BeanFactory apply the Prototype design pattern, with each caller requesting an instance getting an independent instance?
 void setPropertyValues(PropertyValues pvs)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractBeanDefinition

protected AbstractBeanDefinition(PropertyValues pvs,
                                 boolean singleton)
Creates new BeanDefinition
Parameters:
pvs - properties of the bean

AbstractBeanDefinition

protected AbstractBeanDefinition()
Method Detail

isSingleton

public final boolean isSingleton()
Is this a Singleton, with a single, shared instance returned on all calls, or should the BeanFactory apply the Prototype design pattern, with each caller requesting an instance getting an independent instance? How this is defined will depend on the BeanFactory. "Singletons" are the commoner type.
Returns:
whether this is a Singleton

setPropertyValues

public void setPropertyValues(PropertyValues pvs)

getPropertyValues

public PropertyValues getPropertyValues()
Return the PropertyValues to be applied to a new instance of this bean.
Returns:
the PropertyValues to be applied to a new instance of this bean

equals

public boolean equals(java.lang.Object other)
Overrides:
equals in class java.lang.Object
See Also:
Object.equals(Object)


Rod Johnson and Spring contributors 2001-2003.