|
SunSPOT host API V3.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ISpotClientCommand
ISpotClientCommand A command that can be executed by the SpotClient infrastructure.
Field Summary | |
---|---|
static int |
SIGNATURE_BOOLEAN
Return value for getSignature() to show a command that has one boolean argument |
static int |
SIGNATURE_INT
Return value for getSignature() to show a command that has one integer argument |
static int |
SIGNATURE_LONG
Return value for getSignature() to show a command that has one long argument |
static int |
SIGNATURE_NOTHING
Return value for getSignature() to show a command that has no arguments |
static int |
SIGNATURE_OPTIONAL_SECOND_STRING
Return value for getSignature() to show a command that has one required String argument
and a second optional argument that may be null |
static int |
SIGNATURE_OPTIONAL_STRING
Return value for getSignature() to show a command that has one String argument that may be null |
static int |
SIGNATURE_STRING
Return value for getSignature() to show a command that has one String argument |
static int |
SIGNATURE_THREE_STRINGS
Return value for getSignature() to show a command that has three String arguments |
static int |
SIGNATURE_TWO_STRINGS
Return value for getSignature() to show a command that has two String arguments |
Method Summary | |
---|---|
Object |
execute(ISpotClientCommandHelper helper)
If the receiver's getSignature() is SIGNATURE_NOTHING then execute the command,
otherwise throw an IllegalStateException |
Object |
execute(ISpotClientCommandHelper helper,
boolean arg0)
If the receiver's getSignature() is SIGNATURE_BOOLEAN then execute the command,
otherwise throw an IllegalStateException |
Object |
execute(ISpotClientCommandHelper helper,
int arg0)
If the receiver's getSignature() is SIGNATURE_INT then execute the command,
otherwise throw an IllegalStateException |
Object |
execute(ISpotClientCommandHelper helper,
long arg0)
If the receiver's getSignature() is SIGNATURE_LONG then execute the command,
otherwise throw an IllegalStateException |
Object |
execute(ISpotClientCommandHelper helper,
String arg0)
If the receiver's getSignature() is SIGNATURE_STRING or SIGNATURE_OPTIONAL_STRING
then execute the command, otherwise throw an IllegalStateException |
Object |
execute(ISpotClientCommandHelper helper,
String arg0,
String arg1)
If the receiver's getSignature() is SIGNATURE_TWO_STRINGS then execute the command,
otherwise throw an IllegalStateException |
Object |
execute(ISpotClientCommandHelper helper,
String arg0,
String arg1,
String arg2)
If the receiver's getSignature() is SIGNATURE_THREE_STRINGS then execute the command,
otherwise throw an IllegalStateException |
String |
getName()
|
int |
getSignature()
Answer the signature for execution of the command (see various constants SIGNATURE_...) |
String |
getUsage()
|
Field Detail |
---|
static final int SIGNATURE_NOTHING
getSignature()
to show a command that has no arguments
static final int SIGNATURE_INT
getSignature()
to show a command that has one integer argument
static final int SIGNATURE_LONG
getSignature()
to show a command that has one long argument
static final int SIGNATURE_BOOLEAN
getSignature()
to show a command that has one boolean argument
static final int SIGNATURE_STRING
getSignature()
to show a command that has one String argument
static final int SIGNATURE_OPTIONAL_STRING
getSignature()
to show a command that has one String argument that may be null
static final int SIGNATURE_TWO_STRINGS
getSignature()
to show a command that has two String arguments
static final int SIGNATURE_THREE_STRINGS
getSignature()
to show a command that has three String arguments
static final int SIGNATURE_OPTIONAL_SECOND_STRING
getSignature()
to show a command that has one required String argument
and a second optional argument that may be null
Method Detail |
---|
Object execute(ISpotClientCommandHelper helper) throws SpotClientException, IOException
getSignature()
is SIGNATURE_NOTHING
then execute the command,
otherwise throw an IllegalStateException
helper
- TODO
SpotClientException
IOException
Object execute(ISpotClientCommandHelper helper, int arg0) throws SpotClientException, IOException
getSignature()
is SIGNATURE_INT
then execute the command,
otherwise throw an IllegalStateException
helper
- TODO
SpotClientException
IOException
Object execute(ISpotClientCommandHelper helper, long arg0) throws SpotClientException, IOException
getSignature()
is SIGNATURE_LONG
then execute the command,
otherwise throw an IllegalStateException
helper
- TODO
SpotClientException
IOException
Object execute(ISpotClientCommandHelper helper, boolean arg0) throws SpotClientException, IOException
getSignature()
is SIGNATURE_BOOLEAN
then execute the command,
otherwise throw an IllegalStateException
helper
- TODO
SpotClientException
IOException
Object execute(ISpotClientCommandHelper helper, String arg0) throws SpotClientException, IOException
getSignature()
is SIGNATURE_STRING
or SIGNATURE_OPTIONAL_STRING
then execute the command, otherwise throw an IllegalStateException
helper
- TODO
SpotClientException
IOException
Object execute(ISpotClientCommandHelper helper, String arg0, String arg1) throws SpotClientException, IOException
getSignature()
is SIGNATURE_TWO_STRINGS
then execute the command,
otherwise throw an IllegalStateException
helper
- TODO
SpotClientException
IOException
Object execute(ISpotClientCommandHelper helper, String arg0, String arg1, String arg2) throws SpotClientException, IOException
getSignature()
is SIGNATURE_THREE_STRINGS
then execute the command,
otherwise throw an IllegalStateException
helper
- TODO
SpotClientException
IOException
int getSignature()
String getName()
String getUsage()
|
SunSPOT host API V3.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |