Class CommandDispatcher
java.lang.Object
org.jolokia.jvmagent.client.command.CommandDispatcher
Dispatch for various attach commands
- Since:
- 12.08.11
- Author:
- roland
-
Constructor Summary
ConstructorsConstructorDescriptionCommandDispatcher(OptionsAndArgs pOptions) Dispatcher responsible for the execution of commands -
Method Summary
Modifier and TypeMethodDescriptionintdispatchCommand(Object pVm, VirtualMachineHandlerOperations pHandler) Dispatch the commandGet the list of available commandsstatic voidPrint out usage message
-
Constructor Details
-
CommandDispatcher
Dispatcher responsible for the execution of commands- Parameters:
pOptions- the parsed command line and options
-
-
Method Details
-
dispatchCommand
public int dispatchCommand(Object pVm, VirtualMachineHandlerOperations pHandler) throws InvocationTargetException, NoSuchMethodException, IllegalAccessException Dispatch the command- Parameters:
pVm- the virtual machine to attach to (typeless in order avoid direct references to the sun classes)pHandler- handler for listing processes- Returns:
- the return code (0 or 1)
- Throws:
InvocationTargetExceptionNoSuchMethodExceptionIllegalAccessException
-
getAvailableCommands
Get the list of available commands- Returns:
- set of available commands
-
printHelp
public static void printHelp()Print out usage message
-