public interface CommandHandler
CommandHandler
provides the ability to receive MVS console modify
commands, process them, and provide response messages for the command.
A CommandHandler
is delivered MVS console commands which match
its filter. The filter value is defined via the property "modify.filter.regex".
A MVS modify command may be issued as "f
The following is an example of a MVS modify command for a
The "command" delivered to the
The entire "command" portion of the MVS modify command, without the enclosing quotes,
if any, are passed to the CommandHandler
which interacts with the OSGi ConsoleSession support:
f bbgzsrv,'osgi,scr info 51'
CommandHandler
is "osgi,scr info 51".
Note that the single quotes have been removed.
CommandHandler
's handleModify
method.
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
DISPLAY_HELP
Configuration property indicating if help information should be displayed when a
"general" request for help information is requested.
|
static java.lang.String |
MODIFY_FILTER
Configuration property identifying the regular expression used to match
the command string.
|
Modifier and Type | Method and Description |
---|---|
java.util.List<java.lang.String> |
getHelp()
Return help information for this
CommandHandler . |
java.lang.String |
getName()
CommandHandler identity (used in command responses) |
void |
handleModify(java.lang.String modifyCommmand,
ModifyResults results)
This method is driven to process a MVS command which matched the
modify.filter.regex . |
static final java.lang.String MODIFY_FILTER
If this property is not set, the handler will be a target for all modify commands.
The following is an example of a filter property for a CommandHandler
receiving OSGi Console-like commands:
"modify.filter.regex=(\(?i\)\(osgi\).*)"
The filter above ignores case and matches any "command" that begins with "osgi".
static final java.lang.String DISPLAY_HELP
void handleModify(java.lang.String modifyCommmand, ModifyResults results)
modify.filter.regex
.modifyCommmand
- modify command stringresults
- object that can hold the result of processing the commandjava.lang.String getName()
CommandHandler
identity (used in command responses)CommandHandler
java.util.List<java.lang.String> getHelp()
CommandHandler
.