|
SunSPOT host API V6.0 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.spot.client.Flashable
public class Flashable
Flashable represents data to be flashed to a SPOT, which may be either
a host file or an in-memory byte array. It is used in the implementation of various
ISpotClientCommands.
| Constructor Summary | |
|---|---|
Flashable(File file)
Create a Flashable as a wrapper for a host file |
|
Flashable(String name,
byte[] contents)
Create a Flashable as a wrapper for a byte array |
|
| Method Summary | |
|---|---|
void |
checkFileSize(int space)
Check that the file will fit in the available space, and if not, throw SpotClientFailureException |
byte[] |
getContents()
|
InputStream |
getInputStream()
|
String |
getName()
|
long |
length()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Flashable(String name,
byte[] contents)
name - used for user interface reportingcontents - the byte array to be flashed
public Flashable(File file)
throws IOException
file - the file containing the data to be flashed
IOException| Method Detail |
|---|
public long length()
public String getName()
public InputStream getInputStream()
public byte[] getContents()
public void checkFileSize(int space)
SpotClientFailureException
space -
|
SunSPOT host API V6.0 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||