|
Project JXTA | ||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--net.jxta.impl.endpoint.tcp.TcpTransport
This class implements the TCP Transport Protocol
Inner Class Summary | |
class |
TcpTransport.IncomingMulticastThreads
|
class |
TcpTransport.IncomingUnicastThreads
|
protected class |
TcpTransport.TcpDoPing
|
protected class |
TcpTransport.TcpDoPingHandler
|
Field Summary | |
boolean |
debug
|
static int |
DefaultNbOfMulticastThreads
|
static int |
DefaultNbOfUnicastThreads
|
Endpoint |
endpoint
|
static int |
MaxKeepAliveDelay
|
static int |
MaxNbOfMulticastThreads
|
static int |
MaxNbOfPendingSockets
|
static int |
MaxNbOfUnicastKeepAliveThreads
|
static int |
MaxNbOfUnicastThreads
|
static java.lang.String |
multicastAddress
|
static int |
multicastPacketSize
|
static int |
multicastPortNb
|
static java.lang.String |
publicAddress
|
int |
serverSocketPort
|
static int |
unicastPortNb
This is a portion of the API which might not be useful when the configuration part of the JXTA platform will be completed. |
java.net.ServerSocket |
unicastSocket
|
Constructor Summary | |
TcpTransport()
|
|
TcpTransport(net.jxta.protocol.EndpointAdvertisement transport)
|
Method Summary | |
void |
close()
closes this TransportProtocol. |
net.jxta.endpoint.EndpointAddress |
getLocalAddress()
Returns an EndpointAddress of the local endpoint manage by the TransportProtocol |
java.net.InetAddress |
getMcastAddr()
|
int |
getMcastPort()
|
int |
getMcastSize()
|
EndpointMessanger |
getMessanger(net.jxta.endpoint.EndpointAddress dst,
java.lang.String peer,
int type)
Creates and return an EndpointMessanger |
int |
getPort()
|
java.lang.String |
getProtocolName()
Returns a String containing the canonical name of this protocol, as it appears in an EndpointAddress. |
void |
init(Endpoint ep)
Initialization of the TcpTransport (called by Platform) |
boolean |
isConnected()
Returns true if the Transport Protocol can establish connection to the remote host (like TCP). |
boolean |
isFast()
Returns true if the Transport Protocol is fast. |
boolean |
ping(net.jxta.endpoint.EndpointAddress addr)
Returns true if the target address is reachable. |
void |
processMulticast(byte[] buffer)
|
void |
propagate(net.jxta.endpoint.Message message,
java.lang.String pName,
java.lang.String pParams,
java.lang.String prunePeer)
Propagates a TransportMessage on this TransportProtocol |
void |
run()
|
void |
runMulticastServer()
|
void |
runReceive(java.net.Socket socket,
boolean keep)
|
void |
runUnicastServer()
|
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Field Detail |
public boolean debug
public java.net.ServerSocket unicastSocket
public int serverSocketPort
public Endpoint endpoint
public static int unicastPortNb
public static java.lang.String multicastAddress
public static int multicastPortNb
public static int multicastPacketSize
public static java.lang.String publicAddress
public static final int DefaultNbOfUnicastThreads
public static final int MaxNbOfUnicastThreads
public static final int MaxNbOfUnicastKeepAliveThreads
public static final int MaxKeepAliveDelay
public static final int DefaultNbOfMulticastThreads
public static final int MaxNbOfMulticastThreads
public static final int MaxNbOfPendingSockets
Constructor Detail |
public TcpTransport(net.jxta.protocol.EndpointAdvertisement transport)
public TcpTransport()
Method Detail |
public int getPort()
public java.net.InetAddress getMcastAddr()
public int getMcastPort()
public int getMcastSize()
public void init(Endpoint ep)
public void run()
public void runUnicastServer()
public void runMulticastServer()
public void processMulticast(byte[] buffer)
public void runReceive(java.net.Socket socket, boolean keep)
public EndpointMessanger getMessanger(net.jxta.endpoint.EndpointAddress dst, java.lang.String peer, int type) throws java.io.IOException
dest
- EndpointAddress of the destinationtype
- type of the messanger as defined in the class Endpointpublic void propagate(net.jxta.endpoint.Message message, java.lang.String pName, java.lang.String pParams, java.lang.String prunePeer) throws java.io.IOException
message
- the TransportMessage to be propagatedpName
- the name of a servicepParams
- parameters for this message.prunePeer
- ????public java.lang.String getProtocolName()
public void close()
public net.jxta.endpoint.EndpointAddress getLocalAddress()
public boolean isFast()
public boolean isConnected()
public boolean ping(net.jxta.endpoint.EndpointAddress addr)
|
Project JXTA | ||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |