org.objectweb.jonathan.apis.kernel
Interface Factory
- All Known Implementing Classes:
- JContextFactoryFactory, GenericFactory, SimpleChunkFactoryFactory, JDomainFactory, NSRetriever, NSRetriever, JavaSerialService
- public interface Factory
Factory represents the type for factories of bootstrap services.
Factories are used when it is not possible to describe directly an element in the
Kernel.xml configuration file. In this case, factories may be used. A factory should
implement the Factory interface and have a public no-arg constructor.
The factory is registered in the configuration file using a FACTORY
construct stipulating the name of the context element to construct and the
java class name of the factory.
newObject
public Object newObject(Context c)
throws JonathanException
- Returns an object created using information contained in the provided
context.
- Parameters:
context - a Context object;- Returns:
- an object created using information contained in
context. - Throws:
JonathanException - if something goes wrong.