Package org.opennms.netmgt.rtc.datablock
Class RTCNodeKey
- java.lang.Object
-
- org.opennms.netmgt.rtc.datablock.RTCNodeKey
-
- All Implemented Interfaces:
Comparable<RTCNodeKey>
public class RTCNodeKey extends Object implements Comparable<RTCNodeKey>
The key used to look up items in the data map- Author:
- Sowmya Kumaraswamy , OpenNMS.org
-
-
Constructor Summary
Constructors Constructor Description RTCNodeKey(int nodeid, InetAddress ip, String svcname)the constructor for this class
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intcompareTo(RTCNodeKey obj)Implements java.jang.Comparable since this is a key to a tree mapbooleanequals(Object o)Overrides the 'equals()' method in the 'Object' superclassInetAddressgetIP()Return the IP addressintgetNodeID()Return the node IDStringgetSvcName()Return the service nameinthashCode()Overrides the 'hashCode()' method in the 'Object' superclassStringtoString()Returns a string representation of this key
-
-
-
Constructor Detail
-
RTCNodeKey
public RTCNodeKey(int nodeid, InetAddress ip, String svcname)the constructor for this class- Parameters:
nodeid- the node IDip- the node IPsvcname- the service in the node
-
-
Method Detail
-
getNodeID
public int getNodeID()
Return the node ID- Returns:
- the node ID
-
getSvcName
public String getSvcName()
Return the service name- Returns:
- the service name
-
getIP
public InetAddress getIP()
Return the IP address- Returns:
- the IP address
-
hashCode
public int hashCode()
Overrides the 'hashCode()' method in the 'Object' superclass
-
equals
public boolean equals(Object o)
Overrides the 'equals()' method in the 'Object' superclass
-
compareTo
public int compareTo(RTCNodeKey obj)
Implements java.jang.Comparable since this is a key to a tree map- Specified by:
compareToin interfaceComparable<RTCNodeKey>- Parameters:
obj- aRTCNodeKeyobject.- Returns:
- a int.
-
-