public class DefaultCallbackHandler extends ValidatingCallbackHandler implements ParsedCommandLine
operationStr
Constructor and Description |
---|
DefaultCallbackHandler() |
DefaultCallbackHandler(boolean validate) |
DefaultCallbackHandler(OperationRequestAddress prefix) |
assertValidNodeName, assertValidParameterName, assertValidType, start
public DefaultCallbackHandler()
public DefaultCallbackHandler(boolean validate)
public DefaultCallbackHandler(OperationRequestAddress prefix)
@Deprecated public void parse(OperationRequestAddress initialAddress, String argsStr) throws CommandFormatException
CommandFormatException
public void parse(OperationRequestAddress initialAddress, String argsStr, CommandContext ctx) throws CommandFormatException
CommandFormatException
@Deprecated public void parse(OperationRequestAddress initialAddress, String argsStr, boolean validation) throws CommandFormatException
CommandFormatException
public void parse(OperationRequestAddress initialAddress, String argsStr, boolean validation, CommandContext ctx) throws CommandFormatException
CommandFormatException
public void parseOperation(OperationRequestAddress prefix, String argsStr) throws CommandFormatException
CommandFormatException
public void parseHeaders(String argsStr) throws CommandFormatException
CommandFormatException
public void reset()
public String getOriginalLine()
getOriginalLine
in interface ParsedCommandLine
public String getSubstitutedLine()
ParsedCommandLine
getSubstitutedLine
in interface ParsedCommandLine
public List<String> getOtherProperties()
getOtherProperties
in interface ParsedCommandLine
public boolean isRequestComplete()
isRequestComplete
in interface ParsedCommandLine
public boolean endsOnPropertySeparator()
endsOnPropertySeparator
in interface ParsedCommandLine
public boolean endsOnPropertyValueSeparator()
endsOnPropertyValueSeparator
in interface ParsedCommandLine
public boolean endsOnPropertyListStart()
endsOnPropertyListStart
in interface ParsedCommandLine
public boolean endsOnPropertyListEnd()
endsOnPropertyListEnd
in interface ParsedCommandLine
public boolean endsOnHeaderListStart()
endsOnHeaderListStart
in interface ParsedCommandLine
public boolean endsOnAddressOperationNameSeparator()
endsOnAddressOperationNameSeparator
in interface ParsedCommandLine
public boolean endsOnNodeSeparator()
endsOnNodeSeparator
in interface ParsedCommandLine
public boolean endsOnNodeTypeNameSeparator()
endsOnNodeTypeNameSeparator
in interface ParsedCommandLine
public boolean endsOnSeparator()
endsOnSeparator
in interface ParsedCommandLine
public boolean hasAddress()
hasAddress
in interface ParsedCommandLine
public OperationRequestAddress getAddress()
getAddress
in interface ParsedCommandLine
public boolean hasOperationName()
hasOperationName
in interface ParsedCommandLine
public String getOperationName()
getOperationName
in interface ParsedCommandLine
public boolean hasProperties()
hasProperties
in interface ParsedCommandLine
public boolean hasProperty(String propertyName)
hasProperty
in interface ParsedCommandLine
public void validatedNodeType(int index, String nodeType) throws OperationFormatException
validatedNodeType
in class ValidatingCallbackHandler
OperationFormatException
public void nodeTypeNameSeparator(int index)
nodeTypeNameSeparator
in interface CommandLineParser.CallbackHandler
public void validatedNodeName(int index, String nodeName) throws OperationFormatException
validatedNodeName
in class ValidatingCallbackHandler
OperationFormatException
public void nodeSeparator(int index)
nodeSeparator
in interface CommandLineParser.CallbackHandler
public void addressOperationSeparator(int index) throws CommandFormatException
addressOperationSeparator
in interface CommandLineParser.CallbackHandler
CommandFormatException
public void operationName(int index, String operationName) throws OperationFormatException
operationName
in interface CommandLineParser.CallbackHandler
operationName
in class ValidatingCallbackHandler
OperationFormatException
public void validatedOperationName(int index, String operationName) throws OperationFormatException
validatedOperationName
in class ValidatingCallbackHandler
OperationFormatException
public void propertyListStart(int index)
propertyListStart
in interface CommandLineParser.CallbackHandler
public void propertyName(int index, String propertyName) throws OperationFormatException
propertyName
in interface CommandLineParser.CallbackHandler
propertyName
in class ValidatingCallbackHandler
OperationFormatException
protected void validatedPropertyName(int index, String propertyName) throws OperationFormatException
validatedPropertyName
in class ValidatingCallbackHandler
OperationFormatException
public void propertyNameValueSeparator(int index)
propertyNameValueSeparator
in interface CommandLineParser.CallbackHandler
public void property(String name, String value, int nameValueSeparatorIndex) throws OperationFormatException
property
in interface CommandLineParser.CallbackHandler
property
in class ValidatingCallbackHandler
OperationFormatException
protected void validatedProperty(String name, String value, int nameValueSeparatorIndex) throws OperationFormatException
validatedProperty
in class ValidatingCallbackHandler
OperationFormatException
public void propertySeparator(int index)
propertySeparator
in interface CommandLineParser.CallbackHandler
public void propertyListEnd(int index)
propertyListEnd
in interface CommandLineParser.CallbackHandler
public void headerListStart(int index)
headerListStart
in interface CommandLineParser.CallbackHandler
public void headerListEnd(int index)
headerListEnd
in interface CommandLineParser.CallbackHandler
public void headerSeparator(int index)
headerSeparator
in interface CommandLineParser.CallbackHandler
public void headerNameValueSeparator(int index)
headerNameValueSeparator
in interface CommandLineParser.CallbackHandler
public ParsingStateCallbackHandler headerName(int index, String headerName) throws CommandFormatException
headerName
in interface CommandLineParser.CallbackHandler
CommandFormatException
public void header(String name, String value, int valueIndex) throws CommandFormatException
header
in interface CommandLineParser.CallbackHandler
CommandFormatException
public void header(ParsedOperationRequestHeader header)
public boolean hasHeaders()
hasHeaders
in interface ParsedCommandLine
public boolean hasHeader(String name)
hasHeader
in interface ParsedCommandLine
public String getLastHeaderName()
getLastHeaderName
in interface ParsedCommandLine
public Collection<ParsedOperationRequestHeader> getHeaders()
getHeaders
in interface ParsedCommandLine
public ParsedOperationRequestHeader getLastHeader()
getLastHeader
in interface ParsedCommandLine
public void rootNode(int index) throws OperationFormatException
rootNode
in interface CommandLineParser.CallbackHandler
OperationFormatException
public void parentNode(int index)
parentNode
in interface CommandLineParser.CallbackHandler
public void nodeType(int index)
nodeType
in interface CommandLineParser.CallbackHandler
public void nodeName(int index, String nodeName) throws OperationFormatException
nodeName
in interface CommandLineParser.CallbackHandler
nodeName
in class ValidatingCallbackHandler
OperationFormatException
public void nodeType(int index, String nodeType) throws OperationFormatException
nodeType
in interface CommandLineParser.CallbackHandler
nodeType
in class ValidatingCallbackHandler
OperationFormatException
public void nodeTypeOrName(int index, String typeOrName) throws OperationFormatException
nodeTypeOrName
in interface CommandLineParser.CallbackHandler
OperationFormatException
public Set<String> getPropertyNames()
getPropertyNames
in interface ParsedCommandLine
public String getPropertyValue(String name)
getPropertyValue
in interface ParsedCommandLine
public int getLastSeparatorIndex()
getLastSeparatorIndex
in interface ParsedCommandLine
public int getLastChunkIndex()
getLastChunkIndex
in interface ParsedCommandLine
public void outputTarget(int index, String outputTarget)
outputTarget
in interface CommandLineParser.CallbackHandler
public String getOutputTarget()
getOutputTarget
in interface ParsedCommandLine
public String getLastParsedPropertyName()
getLastParsedPropertyName
in interface ParsedCommandLine
public String getLastParsedPropertyValue()
getLastParsedPropertyValue
in interface ParsedCommandLine
public org.jboss.dmr.ModelNode toOperationRequest(CommandContext ctx) throws CommandFormatException
CommandFormatException
public void setFormat(CommandLineFormat format)
setFormat
in interface CommandLineParser.CallbackHandler
public CommandLineFormat getFormat()
getFormat
in interface ParsedCommandLine
public boolean endsOnHeaderSeparator()
endsOnHeaderSeparator
in interface ParsedCommandLine
Copyright © 2023 JBoss by Red Hat. All rights reserved.