Package org.opennms.netmgt.collectd
Class SnmpAttribute
- java.lang.Object
-
- org.opennms.netmgt.collection.support.AbstractCollectionAttribute
-
- org.opennms.netmgt.collectd.SnmpAttribute
-
- All Implemented Interfaces:
CollectionAttribute,CollectionVisitable,Persistable
- Direct Known Subclasses:
AliasedAttribute
public class SnmpAttribute extends AbstractCollectionAttribute
SnmpAttribute class.
- Version:
- $Id: $
- Author:
- ranger
-
-
Field Summary
Fields Modifier and Type Field Description static org.slf4j.LoggerLOG-
Fields inherited from class org.opennms.netmgt.collection.support.AbstractCollectionAttribute
m_attribType, m_resource
-
-
Constructor Summary
Constructors Constructor Description SnmpAttribute(CollectionResource resource, SnmpAttributeType type, SnmpValue val)Constructor for SnmpAttribute.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)StringgetMetricIdentifier()Get the metric identifier for the attribute to be used for NRTG collectionNumbergetNumericValue()getNumericValueStringgetStringValue()getStringValueSnmpValuegetValue()getValueinthashCode()hashCodevoidstoreAttribute(Persister persister)Stores the attribute using the persister.StringtoString()toString-
Methods inherited from class org.opennms.netmgt.collection.support.AbstractCollectionAttribute
getAttributeType, getName, getResource, getType, shouldPersist, visit
-
-
-
-
Constructor Detail
-
SnmpAttribute
public SnmpAttribute(CollectionResource resource, SnmpAttributeType type, SnmpValue val)
Constructor for SnmpAttribute.
- Parameters:
resource- aCollectionResourceobject.type- aSnmpAttributeTypeobject.val- aSnmpValueobject.
-
-
Method Detail
-
storeAttribute
public void storeAttribute(Persister persister)
Stores the attribute using the persister. Not sure this should be here...- Specified by:
storeAttributein interfaceCollectionAttribute- Overrides:
storeAttributein classAbstractCollectionAttribute- Parameters:
persister- aorg.opennms.netmgt.collectd.Persisterobject.
-
toString
public String toString()
toString
-
getMetricIdentifier
public String getMetricIdentifier()
Description copied from interface:CollectionAttributeGet the metric identifier for the attribute to be used for NRTG collection- Returns:
- the metric identifier
-
getNumericValue
public Number getNumericValue()
getNumericValue
- Specified by:
getNumericValuein interfaceCollectionAttribute- Specified by:
getNumericValuein classAbstractCollectionAttribute- Returns:
- a
Stringobject.
-
getStringValue
public String getStringValue()
getStringValue
- Specified by:
getStringValuein interfaceCollectionAttribute- Specified by:
getStringValuein classAbstractCollectionAttribute- Returns:
- a
Stringobject.
-
-