Uses of Interface
org.apache.commons.collections.Factory
-
Packages that use Factory Package Description org.apache.commons.collections This package contains the interfaces and utilities shared across all the subpackages of this component.org.apache.commons.collections.functors This package contains implementations of theClosure
,Predicate
,Transformer
andFactory
interfaces.org.apache.commons.collections.list This package contains implementations of theList
interface.org.apache.commons.collections.map -
-
Uses of Factory in org.apache.commons.collections
Methods in org.apache.commons.collections that return Factory Modifier and Type Method Description static Factory
FactoryUtils. constantFactory(java.lang.Object constantToReturn)
Creates a Factory that will return the same object each time the factory is used.static Factory
FactoryUtils. exceptionFactory()
Gets a Factory that always throws an exception.static Factory
FactoryUtils. instantiateFactory(java.lang.Class classToInstantiate)
Creates a Factory that can create objects of a specific type using a no-args constructor.static Factory
FactoryUtils. instantiateFactory(java.lang.Class classToInstantiate, java.lang.Class[] paramTypes, java.lang.Object[] args)
Creates a Factory that can create objects of a specific type using the arguments specified to this method.static Factory
FactoryUtils. nullFactory()
Gets a Factory that will return null each time the factory is used.static Factory
FactoryUtils. prototypeFactory(java.lang.Object prototype)
Creates a Factory that will return a clone of the same prototype object each time the factory is used.Methods in org.apache.commons.collections with parameters of type Factory Modifier and Type Method Description static Transformer
TransformerUtils. asTransformer(Factory factory)
Creates a Transformer that calls a Factory each time the transformer is used.static java.util.List
ListUtils. lazyList(java.util.List list, Factory factory)
Returns a "lazy" list whose elements will be created on demand.static java.util.Map
MapUtils. lazyMap(java.util.Map map, Factory factory)
Returns a "lazy" map whose values will be created on demand.static java.util.SortedMap
MapUtils. lazySortedMap(java.util.SortedMap map, Factory factory)
Returns a "lazy" sorted map whose values will be created on demand.static java.util.Map
MapUtils. multiValueMap(java.util.Map map, Factory collectionFactory)
Creates a multi-value map backed by the given map which returns collections created by the specified collection factory. -
Uses of Factory in org.apache.commons.collections.functors
Classes in org.apache.commons.collections.functors that implement Factory Modifier and Type Class Description class
ConstantFactory
Factory implementation that returns the same constant each time.class
ExceptionFactory
Factory implementation that always throws an exception.class
InstantiateFactory
Factory implementation that creates a new object instance by reflection.(package private) static class
PrototypeFactory.PrototypeCloneFactory
PrototypeCloneFactory creates objects by copying a prototype using the clone method.(package private) static class
PrototypeFactory.PrototypeSerializationFactory
PrototypeSerializationFactory creates objects by cloning a prototype using serialization.Fields in org.apache.commons.collections.functors declared as Factory Modifier and Type Field Description private Factory
FactoryTransformer. iFactory
The factory to wrapstatic Factory
ExceptionFactory. INSTANCE
Singleton predicate instancestatic Factory
ConstantFactory. NULL_INSTANCE
Returns null each timeMethods in org.apache.commons.collections.functors that return Factory Modifier and Type Method Description Factory
FactoryTransformer. getFactory()
Gets the factory.static Factory
ConstantFactory. getInstance(java.lang.Object constantToReturn)
Factory method that performs validation.static Factory
ExceptionFactory. getInstance()
Factory returning the singleton instance.static Factory
InstantiateFactory. getInstance(java.lang.Class classToInstantiate, java.lang.Class[] paramTypes, java.lang.Object[] args)
Factory method that performs validation.static Factory
PrototypeFactory. getInstance(java.lang.Object prototype)
Factory method that performs validation.Methods in org.apache.commons.collections.functors with parameters of type Factory Modifier and Type Method Description static Transformer
FactoryTransformer. getInstance(Factory factory)
Factory method that performs validation.Constructors in org.apache.commons.collections.functors with parameters of type Factory Constructor Description FactoryTransformer(Factory factory)
Constructor that performs no validation. -
Uses of Factory in org.apache.commons.collections.list
Fields in org.apache.commons.collections.list declared as Factory Modifier and Type Field Description protected Factory
LazyList. factory
The factory to use to lazily instantiate the objectsMethods in org.apache.commons.collections.list with parameters of type Factory Modifier and Type Method Description static java.util.List
LazyList. decorate(java.util.List list, Factory factory)
Factory method to create a lazily instantiating list.Constructors in org.apache.commons.collections.list with parameters of type Factory Constructor Description LazyList(java.util.List list, Factory factory)
Constructor that wraps (not copies). -
Uses of Factory in org.apache.commons.collections.map
Classes in org.apache.commons.collections.map that implement Factory Modifier and Type Class Description private static class
MultiValueMap.ReflectionFactory
Inner class that provides a simple reflection factory.Fields in org.apache.commons.collections.map declared as Factory Modifier and Type Field Description private Factory
MultiValueMap. collectionFactory
The factory for creating value collections.Methods in org.apache.commons.collections.map with parameters of type Factory Modifier and Type Method Description static java.util.Map
DefaultedMap. decorate(java.util.Map map, Factory factory)
Factory method to create a defaulting map.static java.util.Map
LazyMap. decorate(java.util.Map map, Factory factory)
Factory method to create a lazily instantiated map.static java.util.SortedMap
LazySortedMap. decorate(java.util.SortedMap map, Factory factory)
Factory method to create a lazily instantiated sorted map.static MultiValueMap
MultiValueMap. decorate(java.util.Map map, Factory collectionFactory)
Creates a map which decorates the givenmap
and creates the value collections using the suppliedcollectionFactory
.Constructors in org.apache.commons.collections.map with parameters of type Factory Constructor Description LazyMap(java.util.Map map, Factory factory)
Constructor that wraps (not copies).LazySortedMap(java.util.SortedMap map, Factory factory)
Constructor that wraps (not copies).MultiValueMap(java.util.Map map, Factory collectionFactory)
Creates a MultiValueMap which decorates the givenmap
and creates the value collections using the suppliedcollectionFactory
.
-