|
Foundation |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
com.sas.net.connect.SASTelnetClient
public class SASTelnetClient
This class implements enough of the telnet protocol to bootstrap a Connect client.
Constructor Summary | |
---|---|
SASTelnetClient()
Construct a SASTelnetClient. |
|
SASTelnetClient(java.util.Properties properties)
Construct a SASTelnetClient with a list of properties. |
Method Summary | |
---|---|
void |
connect(java.lang.String host)
connect to the telnet daemon on the default port. |
void |
connect(java.lang.String host,
int port)
connect to the telnet daemon. |
void |
disconnect()
disconnect from the telnet daemon. |
com.sas.net.crypto.CipherInterface |
getCipher()
get the cipher object used by the telnet client. |
java.net.Socket |
getSocket()
get the socket used by the telnet client. |
boolean |
isSocketInherited()
true if the ConnectClient should inherit the socket used for the telnet connection. |
char |
receiveChar(int tioTimeout)
receive data from the remote telnet session. |
void |
sendString(java.lang.String inString)
send data to the remote telnet session. |
Constructor Detail |
---|
public SASTelnetClient(java.util.Properties properties)
ISO8859_1
.
\n
. When connecting to a telnet daemon running
on VMS, it is usually necessary to change this value to
\r
.
\r\n
.
properties
- the list of propertiespublic SASTelnetClient()
Method Detail |
---|
public void connect(java.lang.String host, int port) throws TelnetClientException
TelnetClientInterface
connect
in interface TelnetClientInterface
host
- host machine's IP nameport
- TCP port number
TelnetClientException
- if there is an IO errorpublic void disconnect() throws TelnetClientException
TelnetClientInterface
disconnect
in interface TelnetClientInterface
TelnetClientException
- if there is an IO errorpublic char receiveChar(int tioTimeout) throws TelnetClientException
TelnetClientInterface
receiveChar
in interface TelnetClientInterface
tioTimeout
- number of milliseconds to wait for a character to
arrive before throwing an exception. 0
means wait
indefinitely.
TelnetClientException
- if there is an IO error
or if a character does not arrive in the allowed time.public void sendString(java.lang.String inString) throws TelnetClientException
TelnetClientInterface
sendString
in interface TelnetClientInterface
inString
- the string to send
TelnetClientException
- if there is an IO errorpublic boolean isSocketInherited()
TelnetClientInterface
isSocketInherited
in interface TelnetClientInterface
public java.net.Socket getSocket()
TelnetClientInterface
getSocket
in interface TelnetClientInterface
public com.sas.net.crypto.CipherInterface getCipher()
TelnetClientInterface
getCipher
in interface TelnetClientInterface
public void connect(java.lang.String host) throws TelnetClientException
host
- host machine's IP name
TelnetClientException
- if there is an IO error
|
Foundation |
|
| |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |