|
DRCL J-Sim API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectdrcl.DrclObj
drcl.comp.Component
drcl.comp.lib.bytestream.ByteStreamNetPeer
An intermediate component that acts as between a ByteStreamContract
component and a real network socket.
As a reactor, it absorts any size of incoming data from the initiator and sends the data to the real socket. It always reports available buffer size of 1 to keep the initiator sending data.
As an initiator, it relays data from the real socket to the reactor in
bulks of size dataUnit.
| Nested Class Summary |
| Nested classes inherited from class drcl.comp.Component |
Component.Locks |
| Field Summary |
| Fields inherited from interface drcl.comp.lib.bytestream.ByteStreamConstants |
ERROR, QUERY, REPORT, SEND |
| Constructor Summary | |
ByteStreamNetPeer()
|
|
ByteStreamNetPeer(java.lang.String id_)
|
|
| Method Summary | |
void |
accept(int serverPort_)
Sets up a real socket and makes the component listens to the socket. |
void |
connect(java.lang.String serverAddress_,
int serverPort_)
Sets up a real socket and makes the component connects to the real remote socket. |
void |
duplicate(java.lang.Object source_)
Duplicates the content of source_, including ID, name, child components and connections among them, to this component. |
int |
getDataUnit()
|
java.lang.String |
info()
Returns information regarding this component. |
void |
reset()
Resets the component for being used anew. |
void |
setDataUnit(int dataUnit_)
|
| Methods inherited from class drcl.DrclObj |
clone |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public ByteStreamNetPeer()
public ByteStreamNetPeer(java.lang.String id_)
| Method Detail |
public void duplicate(java.lang.Object source_)
Component
duplicate in interface ObjectDuplicableduplicate in class Componentpublic java.lang.String info()
Component
info in class Componentpublic void reset()
Component
reset in class Componentpublic void accept(int serverPort_)
public void connect(java.lang.String serverAddress_,
int serverPort_)
public void setDataUnit(int dataUnit_)
public int getDataUnit()
|
DRCL J-Sim API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||