public class ModelNodes extends Object
ModelNode
.Modifier and Type | Method and Description |
---|---|
static <E extends Enum<E>> |
asEnum(org.jboss.dmr.ModelNode value,
Class<E> targetClass)
Returns the value of the node as an Enum value, or null if the node is undefined.
|
static <E extends Enum<E>> |
asEnum(org.jboss.dmr.ModelNode value,
Class<E> targetClass,
E defaultValue)
Returns the value of the node as an Enum value, or the specified default value if the node is undefined.
|
static float |
asFloat(org.jboss.dmr.ModelNode value)
Returns the value of the node as a float, or null if the node is undefined.
|
static float |
asFloat(org.jboss.dmr.ModelNode value,
float defaultValue)
Returns the value of the node as a string, or the specified default value if the node is undefined.
|
static org.jboss.modules.ModuleIdentifier |
asModuleIdentifier(org.jboss.dmr.ModelNode value)
Returns the value of the node as a module identifier, or null if the node is undefined.
|
static org.jboss.modules.ModuleIdentifier |
asModuleIdentifier(org.jboss.dmr.ModelNode value,
org.jboss.modules.ModuleIdentifier defaultValue)
Returns the value of the node as a module identifier, or the specified default if the node is undefined.
|
static Properties |
asProperties(org.jboss.dmr.ModelNode value)
Returns the value of the node as a properties map, returning an empty properties map if the node is undefined.
|
static List<org.jboss.dmr.Property> |
asPropertyList(org.jboss.dmr.ModelNode value)
Returns the value of the node as a property list, returning an empty list if the node is undefined.
|
static String |
asString(org.jboss.dmr.ModelNode value)
Returns the value of the node as a string, or null if the node is undefined.
|
static String |
asString(org.jboss.dmr.ModelNode value,
String defaultValue)
Returns the value of the node as a string, or the specified default value if the node is undefined.
|
static List<String> |
asStringList(org.jboss.dmr.ModelNode value)
Returns the value of the node as a list of strings, returning an empty list if the node is undefined.
|
public static String asString(org.jboss.dmr.ModelNode value)
value
- a model nodepublic static String asString(org.jboss.dmr.ModelNode value, String defaultValue)
value
- a model nodepublic static float asFloat(org.jboss.dmr.ModelNode value)
value
- a model nodepublic static float asFloat(org.jboss.dmr.ModelNode value, float defaultValue)
value
- a model nodepublic static <E extends Enum<E>> E asEnum(org.jboss.dmr.ModelNode value, Class<E> targetClass)
value
- a model nodepublic static <E extends Enum<E>> E asEnum(org.jboss.dmr.ModelNode value, Class<E> targetClass, E defaultValue)
value
- a model nodepublic static org.jboss.modules.ModuleIdentifier asModuleIdentifier(org.jboss.dmr.ModelNode value)
value
- a model nodepublic static org.jboss.modules.ModuleIdentifier asModuleIdentifier(org.jboss.dmr.ModelNode value, org.jboss.modules.ModuleIdentifier defaultValue)
value
- a model nodepublic static List<org.jboss.dmr.Property> asPropertyList(org.jboss.dmr.ModelNode value)
value
- a model nodepublic static List<String> asStringList(org.jboss.dmr.ModelNode value)
value
- a model nodepublic static Properties asProperties(org.jboss.dmr.ModelNode value)
value
- a model nodeCopyright © 2018 JBoss by Red Hat. All rights reserved.