Class
Tree
          
SUMMARY: INNER | FIELD | CONSTR | METHODDETAIL: FIELD | CONSTR | METHOD
 

com.newstep.solid.comm.rtt
Class RttChannelAccessPoint
com.newstep.solid.management.runtime.AsyncManagedExecutable
  |
  +--com.newstep.solid.comm.ChannelAccessPoint
       |
       +--com.newstep.solid.comm.rtt.RttChannelAccessPoint
All Implemented Interfaces:
       ChannelAccessPointListener, ChannelStatusListener, ManagedExecutable, ManagedExecutableListener

public class RttChannelAccessPoint      
Creates RTT Channels in two flavours: client and server. The client RTT
channel is delivered in the IDLE state, i.e. open() has to be called to
connect it to some host. To set up an RTT server the application has first to
setup a listener for connections using the listen() method. A server RTT
channel is created on accepting a connection from a client.
Implements:
ChannelAccessPointListener
ChannelStatusListener
ManagedExecutableListener
 
Links:
Kernel Association Association Link
to Class ChannelAccessPoint
Associates type:
association
Client cardinality:
1
Client navigability:
NOT NAVIGABLE
Client visibility:
private
Supplier cardinality:
1
Supplier navigability:
NAVIGABLE
Supplier visibility:
private
Custom properties
associates:
TCPChannelAccessPoint
 
Implementation Implementation Link
to Interface ManagedExecutableListener
Creates RTT Channels in two flavours: client and server. The client RTT
channel is delivered in the IDLE state, i.e. open() has to be called to
connect it to some host. To set up an RTT server the application has first to
setup a listener for connections using the listen() method. A server RTT
channel is created on accepting a connection from a client.
 
Generalization Generalization Link
to Class ChannelAccessPoint
Creates RTT Channels in two flavours: client and server. The client RTT
channel is delivered in the IDLE state, i.e. open() has to be called to
connect it to some host. To set up an RTT server the application has first to
setup a listener for connections using the listen() method. A server RTT
channel is created on accepting a connection from a client.
 
Implementation Implementation Link
to Interface ChannelAccessPointListener
Creates RTT Channels in two flavours: client and server. The client RTT
channel is delivered in the IDLE state, i.e. open() has to be called to
connect it to some host. To set up an RTT server the application has first to
setup a listener for connections using the listen() method. A server RTT
channel is created on accepting a connection from a client.
 
Implementation Implementation Link
to Interface ChannelStatusListener
Creates RTT Channels in two flavours: client and server. The client RTT
channel is delivered in the IDLE state, i.e. open() has to be called to
connect it to some host. To set up an RTT server the application has first to
setup a listener for connections using the listen() method. A server RTT
channel is created on accepting a connection from a client.
 
 

Field Summary
private static int
private List
private final static String
private int
private boolean
private boolean
private ConcurrentHashMap
private static Logger
private int
Constructor Summary
public void
RttChannelAccessPoint(ChannelFactory channelFactory, ChannelAccessPoint transportAccessPoint)
Method Summary
public void
protected void
protected void
protected void
protected void
protected void
public void
private Address
findHost(Address address)
public Channel
public void
public void
public void
listen(Address address, ChannelAccessPointListener listener, Integer nrConn)
public void
notify(Channel channel)
public Address
parseString(String string)
public void
public void
public void
public void
public void
public void
public void
public void
public void
Field Detail
channelNumber
private static int channelNumber
Multiplicity:
1
Static.
 

channels
private List channels
Multiplicity:
1
 

className
private final static String className
Final.
Multiplicity:
1
Static.
 

hostId
private int hostId
Multiplicity:
1
 

init
private boolean init
Multiplicity:
1
 

isShutDown
private boolean isShutDown
Multiplicity:
1
 

listeners
private ConcurrentHashMap listeners
Multiplicity:
1
 

logger
private static Logger logger
Multiplicity:
1
Static.
 

thisChannel
private int thisChannel
Multiplicity:
1
 

transportAccessPoint
private ChannelAccessPoint transportAccessPoint
Multiplicity:
1
Custom properties
associates:
TCPChannelAccessPoint
 
Constructor Detail
RttChannelAccessPoint
public void RttChannelAccessPoint (ChannelFactory channelFactory, ChannelAccessPoint transportAccessPoint)
 
Stereotype:
create
 
Method Detail
done
public void done (ManagedExecutable executable)
 
Callback to notify when stopping or shutdown from the channel access
points underneath is done
 

doResume
protected void doResume ()
 
Pass down to the TCP Channel Access Point
Throws:
ExecutableException
 

doShutdown
protected void doShutdown ()
 
Waits for all the channels to close and then passes down to the TCP
Channel Access Point
Throws:
ExecutableException
 

doStart
protected void doStart ()
 
Pass down to the TCP Channel Access Point
Throws:
ExecutableException
 

doStop
protected void doStop ()
 
Pass down to the TCP Channel Access Point
Throws:
ExecutableException
 

doSuspend
protected void doSuspend ()
 
Pass down to the TCP Channel Access Point
Throws:
ExecutableException
 

error
public void error (ManagedExecutable executable)
 
 

findHost
private Address findHost (Address address)
 
Finds the host id stored in the address of this channel
Parameters:
address
Return:
Address
 

getChannel
public Channel getChannel (Address address)
 
Creates an RttChannel with a client role; client code has to open the
channel in order to connect;
Parameters:
address
Host where the client channel connects to
Return:
Channel
Throws:
ChannelException
 

idle
public void idle (ManagedExecutable executable)
 
 

init
public void init (CommConfig config)
 
Initializes the channelAccessPoint and Propagates the configuration file
to the transport access point
Parameters:
config
 

listen
public void listen (Address address, ChannelAccessPointListener listener, Integer nrConn)
 
Starts listening to an address.
Parameters:
address
to listen to : must be a Host ChannelAccessPointListener - a
listener to be notified when a new connection is accepted -
can be null if nobody is to be notified int connections -
number of connections the RTT server can accept : 0 is
unlimited
Throws:
ChannelException
 

notify
public void notify (Channel channel)
 
ChannelAccessPointListener interface; called by the transport access
point when a client connection is accepted Creates a new RTT channel of
server role and adds it in the RTTChannelsTable Propagates the notify if
there is a listener to this channel access point
Parameters:
channel -
the channel that accepted a connection
Throws:
ChannelException
 

parseString
public Address parseString (String string)
 
Address interface. Converts a string to an address of type Host
Parameters:
string
Return:
Address of type Host
Throws:
ChannelException
 

resuming
public void resuming (ManagedExecutable executable)
 
 

running
public void running (ManagedExecutable executable)
 
Callback to be notified when the channel access point is running
 

shuttingDown
public void shuttingDown (ManagedExecutable executable)
 
 

starting
public void starting (ManagedExecutable executable)
 
 

statusChanged
public void statusChanged (Channel channel, ChannelState state)
 
Listens for IDENT message on the RttChannel and notifies the listener
that a new RttChannel of role server has been created
 

stopListen
public void stopListen (Address address)
 
Stops listening to an address
Parameters:
address
the address to stop listening to
Throws:
ChannelException
 

stopping
public void stopping (ManagedExecutable executable)
 
 

suspended
public void suspended (ManagedExecutable executable)
 
 

suspending
public void suspending (ManagedExecutable executable)
 
 

Class
Tree
          
SUMMARY: INNER | FIELD | CONSTR | METHODDETAIL: FIELD | CONSTR | METHOD