JASMI API

com.agentpp.smi
Interface IObject

All Superinterfaces:
java.lang.Comparable, java.io.Serializable
All Known Subinterfaces:
IAgentCapabilities, IComplianceStatement, IGroup, IModule, INotificationType, IObjectType, ITextualConvention

public interface IObject
extends java.io.Serializable, java.lang.Comparable

IObject represents the common super class of all SMI objects.

Version:
1.5
Author:
Frank Fock

Field Summary
static int AGENT_CAPABILITIES
           
static int MODULE_COMPLIANCE
           
static int MODULE_IDENTITY
           
static int NOTIFICATION_GROUP
           
static int NOTIFICATION_TYPE
           
static int OBJECT_GROUP
           
static int OBJECT_IDENTITY
           
static int OBJECT_NAME
           
static int OBJECT_TYPE
           
static int TEXTUAL_CONVENTION
           
static int TRAP_TYPE
           
 
Method Summary
 java.lang.String getComment()
          Get the ASN.1 comment associated with the object.
 IObject getDeepClone()
          Get a deep copy clone of this MIB object.
 java.lang.String getDescription()
          Get the contents of the descritpion clause of the object.
 java.lang.Integer getModuleID()
          Get the module ID of the object.
 java.lang.String getName()
          Get the name of the SMI object.
 IObjectID getObjectID()
          Get the object ID of the object, if present.
 java.lang.String getPrintableOid()
          Return the objects ID as dotted string.
 java.lang.String getReference()
          Get the contents of the reference clause of the object.
 java.lang.String getStatus()
          Returns the status of the object.
 int getType()
          Get the type of the object.
 java.lang.String getTypeString()
          Returns the type of object as a String (e.g., "OBJECT-TYPE", "NOTIFICATION-TYPE", etc.)
 boolean hasComment()
          Check whether the object has got an associated ASN.1 comment.
 boolean hasDescription()
          Check whether the object has a description clause.
 boolean hasReference()
          Check whether the object has a reference clause.
 boolean hasStatus()
          Check whether the object has got a status clause.
 boolean isStructural()
          Returns whether this object definition is structural or whether it defines an object implementation.
 
Methods inherited from interface java.lang.Comparable
compareTo
 

Field Detail

OBJECT_IDENTITY

static final int OBJECT_IDENTITY
See Also:
Constant Field Values

OBJECT_TYPE

static final int OBJECT_TYPE
See Also:
Constant Field Values

TRAP_TYPE

static final int TRAP_TYPE
See Also:
Constant Field Values

NOTIFICATION_TYPE

static final int NOTIFICATION_TYPE
See Also:
Constant Field Values

TEXTUAL_CONVENTION

static final int TEXTUAL_CONVENTION
See Also:
Constant Field Values

MODULE_IDENTITY

static final int MODULE_IDENTITY
See Also:
Constant Field Values

OBJECT_GROUP

static final int OBJECT_GROUP
See Also:
Constant Field Values

NOTIFICATION_GROUP

static final int NOTIFICATION_GROUP
See Also:
Constant Field Values

MODULE_COMPLIANCE

static final int MODULE_COMPLIANCE
See Also:
Constant Field Values

AGENT_CAPABILITIES

static final int AGENT_CAPABILITIES
See Also:
Constant Field Values

OBJECT_NAME

static final int OBJECT_NAME
See Also:
Constant Field Values
Method Detail

getTypeString

java.lang.String getTypeString()
Returns the type of object as a String (e.g., "OBJECT-TYPE", "NOTIFICATION-TYPE", etc.)

Returns:
a String denoting the SMI clause represented by this object.

getStatus

java.lang.String getStatus()
Returns the status of the object.

Returns:
"current", "obsolete", "mandatory", "optional" or "deprecated".

hasStatus

boolean hasStatus()
Check whether the object has got a status clause.

Returns:
true if the object has a status.

getName

java.lang.String getName()
Get the name of the SMI object.

Returns:
a String denoting the name of the SMI object.

getComment

java.lang.String getComment()
Get the ASN.1 comment associated with the object. Comments located within the objects SMI definition are not returned.

Returns:
a String containing any ASN.1 comment lines located above the original definition of the SMI object in the source MIB file.

hasComment

boolean hasComment()
Check whether the object has got an associated ASN.1 comment.

Returns:
true if the object has a ASN.1 comment.

hasDescription

boolean hasDescription()
Check whether the object has a description clause.

Returns:
true if a description is present, false otherwise.

getDescription

java.lang.String getDescription()
Get the contents of the descritpion clause of the object.

Returns:
a String containing the contents of the description clause, including the leading and trailing quotes. If the object does not have a description clause, then null will be returned.

hasReference

boolean hasReference()
Check whether the object has a reference clause.

Returns:
true if a reference is present, false otherwise.

getReference

java.lang.String getReference()
Get the contents of the reference clause of the object.

Returns:
a String containing the contents of the reference clause, including the leading and trailing quotes. If the object does not have a reference clause, then null will be returned.

getObjectID

IObjectID getObjectID()
Get the object ID of the object, if present.

Returns:
an IObjectID instance if the object is not an instance of ITextualConvention.

getPrintableOid

java.lang.String getPrintableOid()
Return the objects ID as dotted string. If the object has no OID (i.e. textual conventions), then an empty string is returned.

Returns:
a String with the objects OID as dotted string (e.g. "1.3.6.1.2")

getDeepClone

IObject getDeepClone()
Get a deep copy clone of this MIB object.

Returns:
an IObject instance that is a "deep copy" of this object. Thus, any member object is also cloned, which is different to the "shallow copy" return by clone().

getModuleID

java.lang.Integer getModuleID()
Get the module ID of the object. The module ID identifies the module the object belongs to.

Returns:
an Integer identifying the source MIB module.

getType

int getType()
Get the type of the object.

Returns:
an int denoting the type of the object. Possible values are defined in this interface.

isStructural

boolean isStructural()
Returns whether this object definition is structural or whether it defines an object implementation.

Returns:
true if the object is a structual object definition, like object names, module identities, or object groups.

JASMI API

JASMI 3
Copyright 2001-2010 Frank Fock
All Rights Reserved