Class DefaultRepository
java.lang.Object
org.apache.xbean.recipe.DefaultRepository
- All Implemented Interfaces:
Repository
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidAdd an object instance to this repository.booleanDoes this repository contain a object with the specified name.Gets the object or recipe with the specified name from this repository.
-
Constructor Details
-
DefaultRepository
public DefaultRepository()
-
-
Method Details
-
contains
Does this repository contain a object with the specified name.- Specified by:
containsin interfaceRepository- Parameters:
name- the unique name of the object instance- Returns:
- true if this repository contain a object with the specified name
-
get
Gets the object or recipe with the specified name from this repository.- Specified by:
getin interfaceRepository- Parameters:
name- the unique name of the object instance- Returns:
- the object instance, a recipe to build the object or null
-
add
Add an object instance to this repository.- Specified by:
addin interfaceRepository- Parameters:
name- the unique name of the instanceinstance- the instance- Throws:
ConstructionException- if another object instance is already registered with the name
-