Interface CollectionResource
-
- All Superinterfaces:
CollectionVisitable,Persistable,ResourceIdentifier
- All Known Implementing Classes:
AbstractCollectionResource,AliasedResource,CollectionResourceWrapper,GenericIndexResource,IfInfo,LatencyCollectionResource,NodeInfo,SnmpCollectionResource
public interface CollectionResource extends ResourceIdentifier, CollectionVisitable, Persistable
CollectionResource interface.
- Version:
- $Id: $
- Author:
- ranger
-
-
Field Summary
Fields Modifier and Type Field Description static StringRESOURCE_TYPE_IFstatic StringRESOURCE_TYPE_LATENCYstatic StringRESOURCE_TYPE_NODE
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description StringgetInstance()Returns the name of the instance thisCollectionResourcerepresents.StringgetInterfaceLabel()Returns a unique label for each resource depending on resource type.ResourcePathgetParent()Returns the name of the parent resource.StringgetResourceTypeName()Returns a string which indicates what type of resource.TimeKeepergetTimeKeeper()Returns a not-nullTimeKeeperinstance when this resource requires to use a special timestamp when updating RRDs/JRBs.StringgetUnmodifiedInstance()Returns the unmodified instance string thisCollectionResourcerepresents.booleanrescanNeeded()rescanNeeded-
Methods inherited from interface org.opennms.netmgt.collection.api.CollectionVisitable
visit
-
Methods inherited from interface org.opennms.netmgt.collection.api.Persistable
shouldPersist
-
Methods inherited from interface org.opennms.netmgt.collection.api.ResourceIdentifier
getOwnerName, getPath
-
-
-
-
Field Detail
-
RESOURCE_TYPE_NODE
static final String RESOURCE_TYPE_NODE
- See Also:
- Constant Field Values
-
RESOURCE_TYPE_IF
static final String RESOURCE_TYPE_IF
- See Also:
- Constant Field Values
-
RESOURCE_TYPE_LATENCY
static final String RESOURCE_TYPE_LATENCY
- See Also:
- Constant Field Values
-
-
Method Detail
-
rescanNeeded
boolean rescanNeeded()
rescanNeeded
- Returns:
- a boolean.
-
getResourceTypeName
String getResourceTypeName()
Returns a string which indicates what type of resource. Will be one of "node" for the node level resource "if" for network interface resources "*" for all other resource types defined in the relevant config files, e.g. hrStorage- Returns:
- a
Stringobject.
-
getParent
ResourcePath getParent()
Returns the name of the parent resource.- Returns:
- a
Stringobject.
-
getInstance
String getInstance()
Returns the name of the instance thisCollectionResourcerepresents. For node level resources, this will be null to indicate the default instance. For interface level resources, some label unique to the node (ifIndex probably). For Generic resources (e.g. the SNMPGenericIndexResource), this will be some identifying label, probably the index in the table. This value is used by theStorageStrategyimplementations to figure out the label for the resource which is used in constructing its RRD directory.- Returns:
- a
Stringobject.
-
getUnmodifiedInstance
String getUnmodifiedInstance()
Returns the unmodified instance string thisCollectionResourcerepresents.- Returns:
- a
Stringobject.
-
getInterfaceLabel
String getInterfaceLabel()
Returns a unique label for each resource depending on resource type. This label is the same label used when constructing the resource ID.- Returns:
- a
Stringobject.
-
getTimeKeeper
TimeKeeper getTimeKeeper()
Returns a not-nullTimeKeeperinstance when this resource requires to use a special timestamp when updating RRDs/JRBs. If the resource doesn't need a specialTimeKeeperit should return null.- Returns:
- a
TimeKeeperobject or null to indicate thatDefaultTimeKeepershould be used.
-
-