Class ResolvePathHandler.Builder
- java.lang.Object
-
- org.jboss.as.controller.services.path.ResolvePathHandler.Builder
-
- Enclosing class:
- ResolvePathHandler
public static class ResolvePathHandler.Builder extends Object
Build an operation to resolve the
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description ResolvePathHandler
build()
Builds the resolve path handler.static ResolvePathHandler.Builder
of(String operationName, PathManager pathManager)
Deprecated.static ResolvePathHandler.Builder
of(PathManager pathManager)
Creates a builder with the default operation name ofresolve-path
.ResolvePathHandler.Builder
setCheckAbsolutePath(boolean checkAbsolutePath)
Sets whether the path is absolute and should ignore the relative-to value.ResolvePathHandler.Builder
setDeprecated(ModelVersion since)
ResolvePathHandler.Builder
setParentAttribute(AttributeDefinition parentAttribute)
Sets the parent attribute that therelative-to
andpath
attributes are children of.ResolvePathHandler.Builder
setPathAttribute(AttributeDefinition pathAttribute)
Sets thepath
attribute.ResolvePathHandler.Builder
setRelativeToAttribute(AttributeDefinition relativeToAttribute)
Sets therelative-to
attribute.
-
-
-
Method Detail
-
of
public static ResolvePathHandler.Builder of(PathManager pathManager)
Creates a builder with the default operation name ofresolve-path
.- Parameters:
pathManager
- the path manager used to resolve the path- Returns:
- the operation handler builder
-
of
@Deprecated public static ResolvePathHandler.Builder of(String operationName, PathManager pathManager)
Deprecated.Creates a builder with the default operation name of defined in theoperationName
parameter. While this seems odd to add a deprecated method from the start, the transaction extension requires a separate operation as there are two relative paths. Other extensions should not use this method and if the transaction subsystem changes to use a proper resource for theobject-store
, this method should be removed.- Parameters:
operationName
- the name of the operation to registerpathManager
- the path manager used to resolve the path- Returns:
- the operation handler builder
-
build
public ResolvePathHandler build()
Builds the resolve path handler.- Returns:
- the operation step handler
-
setParentAttribute
public ResolvePathHandler.Builder setParentAttribute(AttributeDefinition parentAttribute)
Sets the parent attribute that therelative-to
andpath
attributes are children of. A value ofnull
indicates they are a direct decedent of the resource.- Parameters:
parentAttribute
- the parent attribute- Returns:
- the builder
-
setRelativeToAttribute
public ResolvePathHandler.Builder setRelativeToAttribute(AttributeDefinition relativeToAttribute)
Sets therelative-to
attribute. The default value isPathResourceDefinition.RELATIVE_TO
.- Parameters:
relativeToAttribute
- the relative to attribute- Returns:
- the builder
-
setPathAttribute
public ResolvePathHandler.Builder setPathAttribute(AttributeDefinition pathAttribute)
Sets thepath
attribute. The default value isPathResourceDefinition.PATH
.- Parameters:
pathAttribute
- the path to attribute- Returns:
- the builder
-
setDeprecated
public ResolvePathHandler.Builder setDeprecated(ModelVersion since)
-
setCheckAbsolutePath
public ResolvePathHandler.Builder setCheckAbsolutePath(boolean checkAbsolutePath)
Sets whether the path is absolute and should ignore the relative-to value.- Parameters:
checkAbsolutePath
- {code true} if an absolute path should ignore the relative-to value- Returns:
- the builder
-
-