- java.lang.Object
-
- org.snmp4j.agent.mo.snmp.tc.TimeStampTC
-
- All Implemented Interfaces:
TextualConvention<org.snmp4j.smi.TimeTicks>
public class TimeStampTC extends Object implements TextualConvention<org.snmp4j.smi.TimeTicks>
-
-
Constructor Summary
Constructors Constructor Description TimeStampTC()TimeStampTC(org.snmp4j.smi.OctetString defaultContext)Creates aTimestampTCthat uses sysUpTime from the specified context.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description MOColumn<org.snmp4j.smi.TimeTicks>createColumn(int columnID, int syntax, MOAccess access, org.snmp4j.smi.TimeTicks defaultValue, boolean mutableInService)Creates a MOColumn instance of this TC specified by the column ID, access, default value, and mutable flag.org.snmp4j.smi.TimeTickscreateInitialValue()Creates an initial value for an object instance of this textual convention.MOScalar<org.snmp4j.smi.TimeTicks>createScalar(org.snmp4j.smi.OID oid, MOAccess access, org.snmp4j.smi.TimeTicks value)Creates a MOScalar instance of this TC specified by OID, access, and optional value.StringgetModuleName()Returns the MIB module name that defined this textual convention.StringgetName()Returns the name of the textual convention as defined in the MIB module.
-
-
-
Constructor Detail
-
TimeStampTC
public TimeStampTC()
-
TimeStampTC
public TimeStampTC(org.snmp4j.smi.OctetString defaultContext)
Creates aTimestampTCthat uses sysUpTime from the specified context.- Parameters:
defaultContext- the context to be used to provide the sysUpTime for time stamp TCs created by this factory.- Since:
- 1.1
-
-
Method Detail
-
createColumn
public MOColumn<org.snmp4j.smi.TimeTicks> createColumn(int columnID, int syntax, MOAccess access, org.snmp4j.smi.TimeTicks defaultValue, boolean mutableInService)
Description copied from interface:TextualConventionCreates a MOColumn instance of this TC specified by the column ID, access, default value, and mutable flag.- Specified by:
createColumnin interfaceTextualConvention<org.snmp4j.smi.TimeTicks>- Parameters:
columnID- the column id as defined in the MIB module (typically starting at one).syntax- the SMI syntax supported by the column.access- the access definition.defaultValue- the default value ornullif there is no DEFVAL clause for this column.mutableInService-trueif this column may be modified while row is in service.- Returns:
- the MOColumn created.
-
createScalar
public MOScalar<org.snmp4j.smi.TimeTicks> createScalar(org.snmp4j.smi.OID oid, MOAccess access, org.snmp4j.smi.TimeTicks value)
Description copied from interface:TextualConventionCreates a MOScalar instance of this TC specified by OID, access, and optional value.- Specified by:
createScalarin interfaceTextualConvention<org.snmp4j.smi.TimeTicks>- Parameters:
oid- the OID of the scalar isntance.access- the access definition.value- theVariableinstance containing the value of the scalar. Ifvalueisnull, the TC should create an initial value withTextualConvention.createInitialValue().- Returns:
- a MOScalar instance.
-
getModuleName
public String getModuleName()
Description copied from interface:TextualConventionReturns the MIB module name that defined this textual convention.- Specified by:
getModuleNamein interfaceTextualConvention<org.snmp4j.smi.TimeTicks>- Returns:
- an unique module name
-
getName
public String getName()
Description copied from interface:TextualConventionReturns the name of the textual convention as defined in the MIB module.- Specified by:
getNamein interfaceTextualConvention<org.snmp4j.smi.TimeTicks>- Returns:
- the unique name (within the MIB module) of the TC.
-
createInitialValue
public org.snmp4j.smi.TimeTicks createInitialValue()
Description copied from interface:TextualConventionCreates an initial value for an object instance of this textual convention.- Specified by:
createInitialValuein interfaceTextualConvention<org.snmp4j.smi.TimeTicks>- Returns:
- a Variable instance with a valid value (according to this TC).
-
-