|
SunSPOT host API V3.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.spot.client.RemoteLogger
public class RemoteLogger
RemoteLogger. Utility class that assumes a remote SPOT is already executing and redirects its output to System.out.
Constructor Summary | |
---|---|
RemoteLogger(String port,
String remoteId,
int channel,
short pan,
String keyStorePath,
int echoPort)
Launch a RemoteLogger. |
Method Summary | |
---|---|
void |
diagnostic(String msg)
Callback the SpotClient uses to provide diagnostic messages relating to the operation it's executing. |
void |
echoFromTarget(String msg)
Callback the SpotClient uses to echo the output of the target SPOT. |
void |
info(String msg)
Callback the SpotClient uses to provide information messages relating to the operation it's executing. |
static void |
main(String[] args)
Launch a RemoteLogger. |
void |
newProgress(int initialSteps,
int totalSteps,
String title)
Callback the SpotClient uses to announce a new operation for which it will provide progress information. |
void |
progressEnd(String msg)
Callback the SpotClient uses to announce the end of the current operation for which it is providing progress information. |
void |
progressUpdate(int stepsComplete,
String msg)
Callback the SpotClient uses to update progress for lengthy operations. |
void |
quit()
RemoteLogger ignores quit and should not be called. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public RemoteLogger(String port, String remoteId, int channel, short pan, String keyStorePath, int echoPort) throws IOException
port
- serial port for talking to a basestation.remoteId
- id of the remote SPOT whose output is to be echoed.channel
- radio channel to usepan
- radio PAN ID to usekeyStorePath
- fully qualified path to the key file to useechoPort
- radiostream: port on which to receive output from the remote SPOT.
Normally either ISpotAdminConstants.MASTER_ISOLATE_ECHO_PORT
or
ISpotAdminConstants.CHILD_ISOLATE_ECHO_PORT
.
IOException
Method Detail |
---|
public static void main(String[] args) throws IOException
RemoteLogger(String, String, int, short, String, int)
for
details about args.
args
-
IOException
public void info(String msg)
IUI
info
in interface IUI
IUI.info(java.lang.String)
public void echoFromTarget(String msg)
IUI
echoFromTarget
in interface IUI
IUI.echoFromTarget(java.lang.String)
public void newProgress(int initialSteps, int totalSteps, String title)
IUI
newProgress
in interface IUI
initialSteps
- The number of steps already completed (typically 0)totalSteps
- The total number of steps in the operationtitle
- Short description of the operationIUI.newProgress(int, int, java.lang.String)
public void progressUpdate(int stepsComplete, String msg)
IUI
IUI.newProgress(int, int, String)
and before
IUI.progressEnd(String)
then it should be ignored.
progressUpdate
in interface IUI
stepsComplete
- Progress completed so farmsg
- Optional description of the current subtaskIUI.progressUpdate(int, java.lang.String)
public void progressEnd(String msg)
IUI
progressEnd
in interface IUI
msg
- Optional msg describing final completionIUI.progressEnd(java.lang.String)
public void diagnostic(String msg)
IUI
diagnostic
in interface IUI
IUI.diagnostic(java.lang.String)
public void quit()
quit
in interface IUI
|
SunSPOT host API V3.0 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |