public final class ObjectCreateBuilder extends Object
LinkedRuleBuilder.createObject()
.Modifier and Type | Method and Description |
---|---|
protected ObjectCreateRule |
createRule()
Provides an instance of
Rule . |
R |
get()
Provides an instance of
Rule . |
String |
getNamespaceURI()
Returns the namespace URI for which this Rule is relevant, if any.
|
String |
getPattern()
Returns the rule pattern associated to this builder.
|
<T> ObjectCreateBuilder |
ofType(Class<T> type)
Construct an object with the specified class.
|
ObjectCreateBuilder |
ofType(String className)
Construct an object with the specified class name.
|
ObjectCreateBuilder |
ofTypeSpecifiedByAttribute(String attributeName)
Allows specify the attribute containing an override class name if it is present.
|
protected void |
reportError(String methodChain,
String message) |
LinkedRuleBuilder |
then()
Come back to the main
LinkedRuleBuilder . |
ObjectCreateBuilder |
usingConstructor(Class<?>... constructorArgumentTypes)
Allows users to specify constructor argument types.
|
ObjectCreateBuilder |
usingConstructor(String... paramTypeNames)
Allows users to specify constructor argument type names.
|
ObjectCreateBuilder |
usingDefaultConstructorArguments(Object... defaultConstructorArguments)
Allows users to specify default constructor arguments.
|
public ObjectCreateBuilder ofType(String className)
className
- Java class name of the object to be createdpublic <T> ObjectCreateBuilder ofType(Class<T> type)
T
- any java typetype
- Java class of the object to be createdpublic ObjectCreateBuilder ofTypeSpecifiedByAttribute(String attributeName)
attributeName
- The attribute containing an override class name if it is presentpublic ObjectCreateBuilder usingConstructor(String... paramTypeNames)
paramTypeNames
- the constructor argument type namespublic ObjectCreateBuilder usingConstructor(Class<?>... constructorArgumentTypes)
constructorArgumentTypes
- the constructor argument typespublic ObjectCreateBuilder usingDefaultConstructorArguments(Object... defaultConstructorArguments)
defaultConstructorArguments
- the default constructor arguments.protected ObjectCreateRule createRule()
Rule
. Must never return null.public final LinkedRuleBuilder then()
LinkedRuleBuilder
.LinkedRuleBuilder
public final String getNamespaceURI()
public final R get()
Rule
. Must never return null.get
in interface RuleProvider<R extends Rule>
Rule
.protected final void reportError(String methodChain, String message)
public final String getPattern()
Copyright © 2001-2013 The Apache Software Foundation. All Rights Reserved.