|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.objectweb.dream.protocol.bus.BusProtocolImpl.Session
protected class BusProtocolImpl.Session
Field Summary | |
---|---|
protected boolean |
closed
|
protected BusExportIdentifier |
id
|
protected ExportIdentifier[] |
lowerIds
|
protected MessagePassingOutgoingPush |
lowerOutgoingPush
|
protected int |
myAddress
|
protected IncomingPush |
upperIncomingPush
|
Constructor Summary | |
---|---|
protected |
BusProtocolImpl.Session(BusExportIdentifier id,
int myAddress,
IncomingPush upperIncomingPush)
|
Method Summary | |
---|---|
int |
getBusSize()
Returns the size of the bus. |
int |
getLocalAddress()
Returns the address of this protocol instance in the bus. |
void |
incomingClosed(Object outgoingPush,
Exception exception)
Notifies the session, this interface belong, that the lower session accessible through the given interface has been unexpectedly closed. |
void |
incomingPush(Message message)
Gives an incoming message to a protocol. |
void |
outgoingClose(IncomingPush incomingPush)
Closes the communication channel. |
void |
outgoingPush(Message message,
int to)
Gives an outgoing message to a protocol. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected int myAddress
protected BusExportIdentifier id
protected ExportIdentifier[] lowerIds
protected boolean closed
protected MessagePassingOutgoingPush lowerOutgoingPush
protected IncomingPush upperIncomingPush
Constructor Detail |
---|
protected BusProtocolImpl.Session(BusExportIdentifier id, int myAddress, IncomingPush upperIncomingPush)
Method Detail |
---|
public void outgoingPush(Message message, int to) throws PushException
BusOutgoingPush
outgoingPush
in interface BusOutgoingPush
message
- the message to give to the component.to
- the address in the bus of the receiver of the message.
PushException
- if an exception occurs.BusOutgoingPush.outgoingPush(Message, int)
public void outgoingClose(IncomingPush incomingPush) throws IOException
BusOutgoingPush
IncomingPush.incomingClosed(java.lang.Object, java.lang.Exception)
method, since this latter
is only used to inform a upper session that a lower session has been closed
unexpectedly.
outgoingClose
in interface BusOutgoingPush
incomingPush
- the interface on which incoming messages of the closed
communication channel were received.
IOException
- the closing process failed.BusOutgoingPush.outgoingClose(IncomingPush)
public int getLocalAddress()
BusOutgoingPush
getLocalAddress
in interface BusOutgoingPush
BusOutgoingPush.getLocalAddress()
public int getBusSize()
BusOutgoingPush
getBusSize
in interface BusOutgoingPush
BusOutgoingPush.getBusSize()
public void incomingPush(Message message) throws PushException
IncomingPush
incomingPush
in interface IncomingPush
message
- the message to give to the component.
PushException
- if an exception occurs.IncomingPush.incomingPush(Message)
public void incomingClosed(Object outgoingPush, Exception exception)
IncomingPush
incomingClosed
in interface IncomingPush
outgoingPush
- the interface provided by the closed session.exception
- the exception that forced the session to close. May be
null
.IncomingPush.incomingClosed(Object, Exception)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |