org.opennms.netmgt.poller.nrpe
Class NrpePacket
java.lang.Object
org.opennms.netmgt.poller.nrpe.NrpePacket
- public class NrpePacket
- extends java.lang.Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
QUERY_PACKET
public static final short QUERY_PACKET
- See Also:
- Constant Field Values
RESPONSE_PACKET
public static final short RESPONSE_PACKET
- See Also:
- Constant Field Values
HELLO_COMMAND
public static final java.lang.String HELLO_COMMAND
- See Also:
- Constant Field Values
PACKET_VERSION_2
public static final short PACKET_VERSION_2
- See Also:
- Constant Field Values
MAX_PACKETBUFFER_LENGTH
public static final int MAX_PACKETBUFFER_LENGTH
- See Also:
- Constant Field Values
PACKET_SIZE
public static final int PACKET_SIZE
- See Also:
- Constant Field Values
DEFAULT_PADDING
public static final int DEFAULT_PADDING
- See Also:
- Constant Field Values
m_version
private short m_version
m_type
private short m_type
m_resultCode
private short m_resultCode
m_buffer
private java.lang.String m_buffer
NrpePacket
public NrpePacket()
NrpePacket
public NrpePacket(short type,
short resultCode,
java.lang.String buffer)
getVersion
public short getVersion()
setVersion
public void setVersion(short version)
getType
public short getType()
setType
public void setType(short type)
getResultCode
public short getResultCode()
setResultCode
public void setResultCode(short resultCode)
getBuffer
public java.lang.String getBuffer()
setBuffer
public void setBuffer(java.lang.String buffer)
receivePacket
public static NrpePacket receivePacket(java.io.InputStream i,
int padding)
throws NrpeException,
java.io.IOException
- Throws:
NrpeException
java.io.IOException
positive
public static int positive(byte b)
toString
public java.lang.String toString()
buildPacket
public byte[] buildPacket(int padding)
buildPacket
public byte[] buildPacket(int padding,
java.security.SecureRandom random)
Generated by ranger on May 19 2007 2335.