public class AltingConnectionClientImpl<T> extends AltingConnectionClient<T>
Modifier | Constructor and Description |
---|---|
protected |
AltingConnectionClientImpl(AltingChannelInput fromServer,
ChannelOutput openToServer,
ChannelOutput reqToServer,
ChannelOutput backToClient)
Constructs a new instance.
|
Modifier and Type | Method and Description |
---|---|
protected void |
claim()
This claims a lock on the client.
|
boolean |
isOpen()
Returns whether the server has kept its end of the Connection open.
|
protected void |
release()
This releases a lock on the client.
|
T |
reply()
Receives some data back from the server after
request(Object) has been called. |
void |
request(T data)
Sends some data over the connection to server once the
connection has been opened.
|
getAltingChannel, pending, setAltingChannel
protected AltingConnectionClientImpl(AltingChannelInput fromServer, ChannelOutput openToServer, ChannelOutput reqToServer, ChannelOutput backToClient)
public void request(T data) throws java.lang.IllegalStateException
data
- the Object
to send to the server.java.lang.IllegalStateException
- if the method is called when it is
not meant to be.public T reply() throws java.lang.IllegalStateException
request(Object)
has been called.Object
sent from the server.java.lang.IllegalStateException
- if the method is called when it is
not meant to be.public boolean isOpen() throws java.lang.IllegalStateException
reply()
and
before any other Connection method is called.true
iff the server has kept the connection
open.java.lang.IllegalStateException
protected void claim()
protected void release()
Copyright © 1996–2019. All rights reserved.