[jboss-jira] [JBoss JIRA] (WFCORE-111) Add "PathAddress getCurrentAddress()" to OperationContext

Brian Stansberry (JIRA) issues at jboss.org
Wed Sep 17 10:27:03 EDT 2014


    [ https://issues.jboss.org/browse/WFCORE-111?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13003497#comment-13003497 ] 

Brian Stansberry commented on WFCORE-111:
-----------------------------------------

Also, something like this would replace a lot of boilerplate:

{code}
/**
 * Gets the value of the last element of the address associated with the currently executing step.
 * <p>
 * Equivalent to {@code getCurrentAddress().getLastElement().getValue()}.
 *
 * @return the current address' last element's value  
 * @throws IllegalStateException if the current address is the root address
 */
String getCurrentAddressValue();
{code}

> Add "PathAddress getCurrentAddress()" to OperationContext
> ---------------------------------------------------------
>
>                 Key: WFCORE-111
>                 URL: https://issues.jboss.org/browse/WFCORE-111
>             Project: WildFly Core
>          Issue Type: Feature Request
>          Components: Domain Management
>            Reporter: Brian Stansberry
>            Assignee: Brian Stansberry
>
> There's a ton of this in OSH implementations:
> PathAddress.pathAddress(operation.require(ModelDescriptionConstants.OP_ADDR))
> which should be replaced with
> context.getCurrentAddress()



--
This message was sent by Atlassian JIRA
(v6.3.1#6329)


More information about the jboss-jira mailing list