public class SSPagent
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
SSP.ConnectStatus |
status |
Constructor and Description |
---|
SSPagent(java.net.InetAddress Inet)
Create a new SSP instance (no connection is made)
|
SSPagent(java.lang.String clientName)
Create a new SSP instance (no connection is made).
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Close down the agent connection
|
void |
connect()
Connect to the agent
|
boolean |
getDataClass(java.lang.String classStr,
java.io.File outFile)
Get SysInfo data classes specified in comma separated classStr.
|
java.net.InetAddress |
getInetAddress()
Gets the InetAddress for the connection
|
java.lang.String |
getName()
Get the name of the agent
|
int |
getPort()
Get the current SSP Port Number.
|
SSPresponse |
getResponse() |
java.net.Socket |
getSocket()
Get the socket object for this agent
|
SSPresponse |
readCmd()
Read a response from the Agent.
|
void |
sendCmd(java.lang.String Command)
Send a command to the Agent.
|
void |
sendCmd(java.lang.String command,
java.lang.String arg)
Send command with arg as argument.
|
void |
setEncode(SSP.Encode type)
Set the encoding type for client to use to be type.
|
void |
setIn(java.io.BufferedReader value)
Set input stream
|
void |
setInetAddress(java.net.InetAddress Inet)
Set the InetAddress for the agent connection
|
void |
setName(java.lang.String value)
Set the agent's name
|
void |
setOut(java.io.PrintWriter value)
Set output stream
|
void |
setOutFile(java.io.File file)
Set the name of the file to write data output to be file.
|
void |
setPort(int portNum)
Set the SSP Port Number to connect to, to be portNum.
|
void |
setSocket(java.net.Socket value)
Set the socket object for this agent
|
public SSP.ConnectStatus status
public SSPagent(java.lang.String clientName) throws java.net.UnknownHostException
clientName
- java.net.UnknownHostException
public SSPagent(java.net.InetAddress Inet)
Inet
- Address of agent to connect to.public void sendCmd(java.lang.String Command)
public void sendCmd(java.lang.String command, java.lang.String arg)
command
- arg
- public SSPresponse readCmd() throws java.io.IOException
java.io.IOException
public boolean getDataClass(java.lang.String classStr, java.io.File outFile) throws com.magnicomp.sysinfo.common.SysInfoException
classStr
- outFile
- com.magnicomp.sysinfo.common.SysInfoException
public void setOutFile(java.io.File file)
file
- public java.net.InetAddress getInetAddress()
public void setInetAddress(java.net.InetAddress Inet)
public void setName(java.lang.String value)
public java.lang.String getName()
public void setSocket(java.net.Socket value)
public java.net.Socket getSocket()
public void setIn(java.io.BufferedReader value)
public void setOut(java.io.PrintWriter value)
public void setPort(int portNum) throws com.magnicomp.sysinfo.common.SysInfoException
portNum
- com.magnicomp.sysinfo.common.SysInfoException
public int getPort()
public void connect() throws com.magnicomp.sysinfo.common.SysInfoException
com.magnicomp.sysinfo.common.SysInfoException
public void close()
public SSPresponse getResponse()
public void setEncode(SSP.Encode type) throws com.magnicomp.sysinfo.common.SysInfoException
type
- com.magnicomp.sysinfo.common.SysInfoException