public class ServerSpace extends ServerSpace
DEBUG, DEFAULT_UNUSED_STRING, driver, spaceId
Constructor and Description |
---|
ServerSpace(ServerInterpreter serverInterpreter,
String serverName,
String driverName,
String title,
String blockInfo,
int tileNum,
String unused,
boolean mainSpace)
Create a new GCspy Space
|
Modifier and Type | Method and Description |
---|---|
Address |
addStream(int streamId)
Add a stream to the native driver
|
void |
resize(int size)
Tell the C driver to resize
|
void |
sendControls(AbstractDriver space,
int tileNum)
Send all the control info for the space
|
void |
setTilename(int i,
Address start,
Address end)
Tell the native driver the tile name.
|
void |
setTilename(int i,
Address format,
long value)
Tell the native driver the tile name.
|
void |
setTilename(int i,
String format,
long value)
Tell the native driver the tile names.
|
void |
spaceInfo(Address info)
Send info for this space
|
void |
startCommunication()
Start a transmission
|
void |
stream(int streamId,
int len)
Start transmitting a stream.
|
void |
streamByteValue(byte value)
Send a byte
|
void |
streamEnd()
End of this stream
|
void |
streamIntValue(int value)
Send an int
|
void |
streamShortValue(short value)
Send a short
|
void |
summary(int streamId,
int len)
Start to send a summary
|
void |
summaryEnd()
End the summary
|
void |
summaryValue(int val)
Send a summary value
|
endCommunication
public ServerSpace(ServerInterpreter serverInterpreter, String serverName, String driverName, String title, String blockInfo, int tileNum, String unused, boolean mainSpace)
serverInterpreter
- The server that owns this spaceserverName
- The server's namedriverName
- The space driver's nametitle
- Title for the spaceblockInfo
- A label for each blocktileNum
- Max number of tiles in this spaceunused
- A label for unused blocksmainSpace
- Whether this space is the main spacepublic void setTilename(int i, Address start, Address end)
setTilename
in class ServerSpace
i
- the number of the tilestart
- the starting address of the tileend
- the end addresspublic void setTilename(int i, Address format, long value)
ServerSpace
setTilename
in class ServerSpace
i
- the number of the tileformat
- the name of the tile, a format stringvalue
- The value for the format stringpublic void setTilename(int i, String format, long value)
ServerSpace
setTilename
in class ServerSpace
i
- the number of the tileformat
- The name, including format tagsvalue
- The value for the format stringpublic void resize(int size)
ServerSpace
resize
in class ServerSpace
size
- the new driver sizepublic void startCommunication()
ServerSpace
startCommunication
in class ServerSpace
public Address addStream(int streamId)
ServerSpace
addStream
in class ServerSpace
streamId
- the stream's IDgcspy_gc_stream_t
public void stream(int streamId, int len)
ServerSpace
stream
in class ServerSpace
streamId
- The stream's IDlen
- The number of items in the streampublic void streamByteValue(byte value)
ServerSpace
streamByteValue
in class ServerSpace
value
- The bytepublic void streamShortValue(short value)
ServerSpace
streamShortValue
in class ServerSpace
value
- The shortpublic void streamIntValue(int value)
ServerSpace
streamIntValue
in class ServerSpace
value
- The intpublic void streamEnd()
ServerSpace
streamEnd
in class ServerSpace
public void summary(int streamId, int len)
ServerSpace
summary
in class ServerSpace
streamId
- The stream's IDlen
- The number of items to be sentpublic void summaryValue(int val)
ServerSpace
summaryValue
in class ServerSpace
val
- The valuepublic void summaryEnd()
ServerSpace
summaryEnd
in class ServerSpace
public void sendControls(AbstractDriver space, int tileNum)
ServerSpace
sendControls
in class ServerSpace
space
- The GCspy driver for this spacetileNum
- The number of tilespublic void spaceInfo(Address info)
ServerSpace
spaceInfo
in class ServerSpace
info
- A pointer to the information (held as C string)