Package org.apache.commons.collections
Interface Factory
- All Known Implementing Classes:
ConstantFactory,ExceptionFactory,InstantiateFactory
Deprecated.
Apache Commons Collections version 3.x is being deprecated from AEMaaCS. The upgraded version 4.4 of Commons Collections is already included as replacement. Customers are advised to upgrade to this version of the library. Please note: the package name was changed to org.apache.commons.collections4. Further note that there are AEM APIs currently exposing the old collections classes; these will be updated in upcoming releases.
Defines a functor interface implemented by classes that create objects.
A Factory creates an object without using an input parameter.
If an input parameter is required, then Transformer is more appropriate.
Standard implementations of common factories are provided by
FactoryUtils. These include factories that return a constant,
a copy of a prototype or a new instance.
- Since:
- Commons Collections 2.1
-
Method Summary
-
Method Details
-
create
Object create()Deprecated.Create a new object.- Returns:
- a new object
- Throws:
FunctorException- (runtime) if the factory cannot create an object
-