SunSPOT API V3.0


com.sun.spot.peripheral.ota
Interface IOTACommand

All Known Implementing Classes:
OTAExtension

public interface IOTACommand

IOTACommand: a SPOT admin command. See IOTACommandProcessorExtension for details of extending the default set of SPOT admin commands. A single IOTACommand instance may implement one or more SPOT admin commands.


Method Summary
 int getSecurityLevelFor(String command)
          Answer the security level for a command.
 boolean processCommand(String command, DataInputStream params, IOTACommandHelper helper)
          Attempt to process a command.
 

Method Detail

processCommand

boolean processCommand(String command,
                       DataInputStream params,
                       IOTACommandHelper helper)
                       throws IOException
Attempt to process a command.

Parameters:
command - the command that was invoked
params - a DataInputStream from which the command's parameters can be read
helper - infrastructure-supplied source of command helper operations
Returns:
false if the SPOT admin command processor should closedown as a result of this command being run, otherwise true. Return true even when the command failed.
Throws:
IOException

getSecurityLevelFor

int getSecurityLevelFor(String command)
Answer the security level for a command. See IOTACommandHelper.DEVICE_SECURITY_LEVEL

Parameters:
command - the command in question
Returns:
the security level

SunSPOT API V3.0


Copyright © 2006, 2007 Sun Microsystems, Inc. All Rights Reserved.