|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jage.platform.component.builder.MapBuilder
public final class MapBuilder
This Builder adds several methods specific to Map Components.
Nested Class Summary | |
---|---|
class |
MapBuilder.MapKey
|
class |
MapBuilder.MapValue
|
Method Summary | |
---|---|
ComponentBuilder |
Agent(String name,
Class<?> type)
Alias for a component with no singleton scope. |
ArrayBuilder |
Array(String name,
Class<?> type)
Declares an array component with a given name and element type. |
ArrayBuilder |
Array(String name,
Class<?> type,
boolean isSingleton)
Declares an array component with a given name, element type, and scope. |
Configuration |
build()
Returns the configuration described with this builder. |
ComponentBuilder |
Component(String name,
Class<?> type)
Declares a component with a given name, type. |
ComponentBuilder |
Component(String name,
Class<?> type,
boolean isSingleton)
Declares a component with a given name, type, and scope. |
protected AbstractComponentDefinition |
getCurrentDefinition()
|
CollectionBuilder |
List(String name)
Declares a list component with a given name. |
CollectionBuilder |
List(String name,
Class<?> type)
Declares a list component with a given name and element type. |
CollectionBuilder |
List(String name,
Class<?> type,
boolean isSingleton)
Declares a list component with a given name, element type, and scope. |
MapBuilder |
Map(String name)
Declares a map component with a given name. |
MapBuilder |
Map(String name,
Class<?> keyType,
Class<?> valueType)
Declares a map component with a given name, key type and value type. |
MapBuilder |
Map(String name,
Class<?> keyType,
Class<?> valueType,
boolean isSingleton)
Declares a map component with a given name, key type, value type, and scope. |
protected ISingleValueProvider |
reference(String targetName)
|
CollectionBuilder |
Set(String name)
Declares a set component with a given name. |
CollectionBuilder |
Set(String name,
Class<?> type)
Declares a set component with a given name and element type. |
CollectionBuilder |
Set(String name,
Class<?> type,
boolean isSingleton)
Declares a set component with a given name, element type, and scope. |
ComponentBuilder |
Strategy(String name,
Class<?> type)
Alias for a component with singleton scope. |
protected ISingleValueProvider |
value(Class<?> type,
String stringValue)
|
MapBuilder |
withConstructorArg(Class<?> type,
String stringValue)
Adds a constructor value argument to the current component definition. |
MapBuilder |
withConstructorArgRef(String targetName)
Adds a constructor reference argument to the current component definition. |
IConfigurationBuilder |
withInner(Configuration innerConfiguration)
Nests the given configuration the current component definition. |
IConfigurationBuilder |
withInner(IConfigurationBuilder innerConfigurationBuilder)
Nests the configuration described by the given builder in the current component definition. |
MapBuilder.MapKey |
withItem()
Adds an item to the current Map definition. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
protected AbstractComponentDefinition getCurrentDefinition()
public MapBuilder withConstructorArg(Class<?> type, String stringValue)
type
- The argument's typestringValue
- The argument's string value.
public MapBuilder withConstructorArgRef(String targetName)
targetName
- The target component's name.
public MapBuilder.MapKey withItem()
public final IConfigurationBuilder withInner(IConfigurationBuilder innerConfigurationBuilder)
innerConfigurationBuilder
- The inner builder to be nested
public final IConfigurationBuilder withInner(Configuration innerConfiguration)
innerConfigurationBuilder
- The inner builder to be nested
public final ComponentBuilder Component(String name, Class<?> type)
IConfigurationBuilder
Component
in interface IConfigurationBuilder
name
- The component's name.type
- The component's type.
public final ComponentBuilder Component(String name, Class<?> type, boolean isSingleton)
IConfigurationBuilder
Component
in interface IConfigurationBuilder
name
- The component's name.type
- The component's type.isSingleton
- whether this component has a singleton scope.
public final ComponentBuilder Agent(String name, Class<?> type)
IConfigurationBuilder
Agent
in interface IConfigurationBuilder
name
- The component's name.type
- The component's type.
public final ComponentBuilder Strategy(String name, Class<?> type)
IConfigurationBuilder
Strategy
in interface IConfigurationBuilder
name
- The component's name.type
- The component's type.
public final CollectionBuilder Set(String name)
IConfigurationBuilder
Set
in interface IConfigurationBuilder
name
- The component's name.
public final CollectionBuilder Set(String name, Class<?> type)
IConfigurationBuilder
Set
in interface IConfigurationBuilder
name
- The component's name.type
- The component's element type.
public final CollectionBuilder Set(String name, Class<?> type, boolean isSingleton)
IConfigurationBuilder
Set
in interface IConfigurationBuilder
name
- The component's name.type
- The component's element type.isSingleton
- whether this component has a singleton scope.
public final CollectionBuilder List(String name)
IConfigurationBuilder
List
in interface IConfigurationBuilder
name
- The component's name.
public final CollectionBuilder List(String name, Class<?> type)
IConfigurationBuilder
List
in interface IConfigurationBuilder
name
- The component's name.type
- The component's element type.
public final CollectionBuilder List(String name, Class<?> type, boolean isSingleton)
IConfigurationBuilder
List
in interface IConfigurationBuilder
name
- The component's name.type
- The component's element type.isSingleton
- whether this component has a singleton scope.
public final ArrayBuilder Array(String name, Class<?> type)
IConfigurationBuilder
Array
in interface IConfigurationBuilder
name
- The component's name.type
- The component's element type.
public final ArrayBuilder Array(String name, Class<?> type, boolean isSingleton)
IConfigurationBuilder
Array
in interface IConfigurationBuilder
name
- The component's name.type
- The component's element type.isSingleton
- whether this component has a singleton scope.
public MapBuilder Map(String name)
IConfigurationBuilder
Map
in interface IConfigurationBuilder
name
- The component's name.
public MapBuilder Map(String name, Class<?> keyType, Class<?> valueType)
IConfigurationBuilder
Map
in interface IConfigurationBuilder
name
- The component's name.keyType
- The component's key type.valueType
- The component's value type.
public MapBuilder Map(String name, Class<?> keyType, Class<?> valueType, boolean isSingleton)
IConfigurationBuilder
Map
in interface IConfigurationBuilder
name
- The component's name.keyType
- The component's key type.valueType
- The component's value type.isSingleton
- whether this component has a singleton scope.
public final Configuration build()
IConfigurationBuilder
build
in interface IConfigurationBuilder
protected final ISingleValueProvider value(Class<?> type, String stringValue)
protected final ISingleValueProvider reference(String targetName)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |