public class ServiceInputConnection extends java.lang.Object implements IInputConnection
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
closed
The closed flag.
|
protected IInputConnection |
con
The remote output connection.
|
protected jadex.commons.future.SubscriptionIntermediateFuture<byte[]> |
future
The buffer.
|
protected jadex.commons.ICommand |
transfercommand
The transfer future.
|
protected jadex.commons.future.ITerminableIntermediateFuture<java.lang.Long> |
transferfuture
The transfer future.
|
| Constructor and Description |
|---|
ServiceInputConnection()
Create a new service input connection.
|
| Modifier and Type | Method and Description |
|---|---|
jadex.commons.future.ISubscriptionIntermediateFuture<byte[]> |
aread()
Asynchronous read.
|
int |
available()
Get the number of available bytes.
|
void |
close()
Close the stream.
|
int |
getConnectionId()
Get the connection id.
|
ITransportComponentIdentifier |
getInitiator()
Get the initiator.
|
java.util.Map<java.lang.String,java.lang.Object> |
getNonFunctionalProperties()
Get the non-functional properties of the connection.
|
IOutputConnection |
getOutputConnection()
Get the corresponding output connection.
|
ITransportComponentIdentifier |
getParticipant()
Get the participant.
|
int |
read()
Non-blocking read.
|
int |
read(byte[] buffer)
Non-blocking read.
|
protected void |
setInputConnection(IInputConnection con)
Set the input connection.
|
jadex.commons.future.ISubscriptionIntermediateFuture<java.lang.Long> |
writeToOutputStream(java.io.OutputStream os,
IExternalAccess component)
Read all data from output stream to the connection.
|
protected IInputConnection con
protected boolean closed
protected jadex.commons.future.SubscriptionIntermediateFuture<byte[]> future
protected jadex.commons.future.ITerminableIntermediateFuture<java.lang.Long> transferfuture
protected jadex.commons.ICommand transfercommand
public ServiceInputConnection()
public int read()
read in interface IInputConnectionpublic int read(byte[] buffer)
read in interface IInputConnectionbuffer - The buffer to read in.public jadex.commons.future.ISubscriptionIntermediateFuture<byte[]> aread()
aread in interface IInputConnectionpublic int available()
available in interface IInputConnectionpublic int getConnectionId()
getConnectionId in interface IConnectionpublic void close()
close in interface IConnectionpublic ITransportComponentIdentifier getInitiator()
getInitiator in interface IConnectionpublic ITransportComponentIdentifier getParticipant()
getParticipant in interface IConnectionpublic java.util.Map<java.lang.String,java.lang.Object> getNonFunctionalProperties()
getNonFunctionalProperties in interface IConnectionprotected void setInputConnection(IInputConnection con)
public IOutputConnection getOutputConnection()
public jadex.commons.future.ISubscriptionIntermediateFuture<java.lang.Long> writeToOutputStream(java.io.OutputStream os,
IExternalAccess component)
writeToOutputStream in interface IInputConnectionis - The input stream.component - The component.