|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectdrastic.mCmdIF.SocketManager
Title: SocketManager
Description: Track sockets for reuse by multiple callers. Uses the SocketData class to manage/track each individual socket. Do not call directly, use MediaCmdIF which uses VVWNetCmdSender to communicate with this SocketManager.
Copyright: Copyright © 2004-2007
Company: Drastic Technologies Ltd.
523 The Queensway, Suite 102
Toronto, ON, M8Y 1J7
CANADA
416 255 5636
fax 255 8780
http://www.drastictech.com
engineering@drastictech.com
SocketManager.SocketData
,
VVWNETCMDSENDER
Nested Class Summary | |
(package private) class |
SocketManager.SocketData
Title: SocketData |
Field Summary | |
private int |
m_timeOut
Length of time in milliseconds to wait for a socket to connect. |
(package private) java.util.LinkedList |
SocketList
The list of active sockets - NOTE: To maintain backward compatibility, do NOT parameterize this |
Constructor Summary | |
SocketManager()
SocketManager |
Method Summary | |
(package private) boolean |
Close(java.net.InetAddress inetAddress,
int dwPort,
boolean fAllInstances)
Close the socket. |
(package private) SocketManager.SocketData |
Find(java.net.InetAddress inetAddress,
int dwPort)
Find a socket that has already been opened. |
(package private) java.io.InputStream |
GetInputStream(java.net.InetAddress inetAddress,
int dwPort)
Get the input stream. |
(package private) java.io.OutputStream |
GetOutputStream(java.net.InetAddress inetAddress,
int dwPort)
Get the output stream. |
(package private) boolean |
IsSocketConnected(java.net.InetAddress inetAddress,
int dwPort)
Returns whether we have a connection to this socket/port or not. |
(package private) boolean |
Open(java.net.InetAddress inetAddress,
int dwPort)
Open a socket. |
(package private) void |
setTimeout(java.net.InetAddress inetAddress,
int dwPort,
int nTimeOut)
Changes the tpcip (SoTimeOut) timeout value for a socket. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
java.util.LinkedList SocketList
private int m_timeOut
Constructor Detail |
public SocketManager()
Method Detail |
SocketManager.SocketData Find(java.net.InetAddress inetAddress, int dwPort)
inetAddress
- InetAddress the target machine address or namedwPort
- int the port to connect on
boolean Open(java.net.InetAddress inetAddress, int dwPort)
inetAddress
- InetAddress the ip address or name to attach todwPort
- int the port to attach on
boolean IsSocketConnected(java.net.InetAddress inetAddress, int dwPort)
inetAddress
- InetAddress the ip address or name to attach todwPort
- int the port to attach on
void setTimeout(java.net.InetAddress inetAddress, int dwPort, int nTimeOut)
inetAddress
- InetAddress the ip address or name to attach todwPort
- int the port to attach onnTimeOut
- int new time out value for the socketboolean Close(java.net.InetAddress inetAddress, int dwPort, boolean fAllInstances)
inetAddress
- InetAddress the ip address or name to closedwPort
- int the port to closefAllInstances
- boolean if true, close the actual socket. if false,
reduce the reference count until it is 1, then close the actual socket
java.io.InputStream GetInputStream(java.net.InetAddress inetAddress, int dwPort)
inetAddress
- InetAddress the ip address or name to attach todwPort
- int the port to attach on
java.io.OutputStream GetOutputStream(java.net.InetAddress inetAddress, int dwPort)
inetAddress
- InetAddress the ip address or name to attach todwPort
- int the port to attach on
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |