org.opennms.netmgt.collectd
Class SnmpAttributeType
java.lang.Object
org.opennms.netmgt.collectd.SnmpAttributeType
- All Implemented Interfaces:
- AttributeDefinition, CollectionAttributeType
- Direct Known Subclasses:
- NumericAttributeType, StringAttributeType
public abstract class SnmpAttributeType
- extends Object
- implements AttributeDefinition, CollectionAttributeType
Represents an OID to be collected (it might be specific or an indexed object).
Also specific to a collection (e.g.: "default"), resource type (e.g.: node or
interface), and attribute group (data collection group name, e.g.: "mib2-interfaces").
This is extended to create concreate classes that represent specific types of data
to be stored such as numeric data ((NumericAttributeType)) or string data
((StringAttributeType)).
SnmpAttributeType
protected SnmpAttributeType(ResourceType resourceType,
String collectionName,
MibObject mibObj,
AttributeGroupType groupType)
getCollectionName
protected String getCollectionName()
getCollectionTrackers
public static List<Collectable> getCollectionTrackers(Collection<SnmpAttributeType> objList)
create
public static SnmpAttributeType create(ResourceType resourceType,
String collectionName,
MibObject mibObj,
AttributeGroupType groupType)
getResourceType
public ResourceType getResourceType()
getGroupType
public AttributeGroupType getGroupType()
- Specified by:
getGroupType in interface CollectionAttributeType
getGroupName
public String getGroupName()
getAlias
public String getAlias()
getOid
public String getOid()
getInstance
public String getInstance()
getType
public String getType()
- Specified by:
getType in interface AttributeDefinition
getName
public String getName()
- Specified by:
getName in interface AttributeDefinition
storeAttribute
public abstract void storeAttribute(CollectionAttribute attribute,
Persister persister)
- Specified by:
storeAttribute in interface CollectionAttributeType
storeResult
public void storeResult(SnmpCollectionSet collectionSet,
SNMPCollectorEntry entry,
SnmpObjId base,
SnmpInstId inst,
SnmpValue val)
toString
public String toString()
- Overrides:
toString in class Object
equals
public boolean equals(Object obj)
- Specified by:
equals in interface AttributeDefinition- Overrides:
equals in class Object
hashCode
public int hashCode()
- Specified by:
hashCode in interface AttributeDefinition- Overrides:
hashCode in class Object
log
public Category log()
getGroupIfType
public String getGroupIfType()
matches
public boolean matches(SnmpObjId base,
SnmpInstId inst)
Copyright © 2009. All Rights Reserved.