org.springframework.beans.factory.config
Class SetFactoryBean
- public class SetFactoryBean
- implements FactoryBean, InitializingBean
Simple factory for shared Set instances. Allows for central setup
of Sets via the "set" element in XML bean definitions.
- Author:
- Juergen Hoeller
- Since: 21.01.2003
afterPropertiesSet
public void afterPropertiesSet()
getObject
public Object getObject()
getObjectType
public Class getObjectType()
isSingleton
public boolean isSingleton()
setSingleton
public void setSingleton(boolean singleton)
- Set if a singleton should be created, or a new object
on each request else. Default is true.
setSourceSet
public void setSourceSet(Set sourceSet)
- Set the source Set, typically populated via XML "set" elements.
setTargetSetClass
public void setTargetSetClass(Class targetSetClass)
- Set the class to use for the target Set.
Default is
java.util.HashSet.- See Also:
- HashSet
to Class java.util.Set
to Class java.lang.Class
to Class java.util.Set