public class

SnmpCounter64

extends SnmpValue
java.lang.Object
   ↳ com.sun.jmx.snmp.SnmpValue
     ↳ com.sun.jmx.snmp.SnmpCounter64

Class Overview

Represents an SNMP 64bits counter.

This API is a Sun Microsystems internal API and is subject to change without notice.

Summary

[Expand]
Inherited Constants
From interface com.sun.jmx.snmp.SnmpDataTypeEnums
Public Constructors
SnmpCounter64(long v)
Constructs a new SnmpCounter64 from the specified long value.
SnmpCounter64(Long v)
Constructs a new SnmpCounter64 from the specified Long value.
Public Methods
static void appendToOid(SnmpOid source, SnmpOid dest)
Appends an SnmpOid representing an SnmpCounter64 to another OID.
synchronized final Object clone()
Clones the SnmpCounter64 object, making a copy of its data.
synchronized final SnmpValue duplicate()
Performs a clone action.
final String getTypeName()
Returns a textual description of the type object.
int intValue()
Converts the counter value to its integer form.
long longValue()
Returns the counter value of this SnmpCounter64.
static int nextOid(long[] index, int start)
Scans an index OID, skips the counter value and returns the position of the next value.
Integer toInteger()
Converts the counter value to its Integer form.
Long toLong()
Converts the counter value to its Long form.
SnmpOid toOid()
Converts the counter value to its SnmpOid form.
static SnmpOid toOid(long[] index, int start)
Extracts the counter from an index OID and returns its value converted as an SnmpOid.
String toString()
Converts the counter value to its String form.
[Expand]
Inherited Methods
From class com.sun.jmx.snmp.SnmpValue
From class java.lang.Object

Public Constructors

public SnmpCounter64 (long v)

Constructs a new SnmpCounter64 from the specified long value.

Parameters
v The initialization value.
Throws
IllegalArgumentException The specified value is negative or larger than Long.MAX_VALUE.

public SnmpCounter64 (Long v)

Constructs a new SnmpCounter64 from the specified Long value.

Parameters
v The initialization value.
Throws
IllegalArgumentException The specified value is negative or larger than Long.MAX_VALUE.

Public Methods

public static void appendToOid (SnmpOid source, SnmpOid dest)

Appends an SnmpOid representing an SnmpCounter64 to another OID.

Parameters
source An OID representing an SnmpCounter64 value.
dest Where source should be appended.

public final synchronized Object clone ()

Clones the SnmpCounter64 object, making a copy of its data.

Returns
  • The object clone.

public final synchronized SnmpValue duplicate ()

Performs a clone action. This provides a workaround for the SnmpValue interface.

Returns
  • The SnmpValue clone.

public final String getTypeName ()

Returns a textual description of the type object.

Returns
  • ASN.1 textual description.

public int intValue ()

Converts the counter value to its integer form.

Returns
  • The integer representation of the value.

public long longValue ()

Returns the counter value of this SnmpCounter64.

Returns
  • The value.

public static int nextOid (long[] index, int start)

Scans an index OID, skips the counter value and returns the position of the next value.

Parameters
index The index array.
start The position in the index array.
Returns
  • The position of the next value.
Throws
SnmpStatusException There is no counter value available at the start position.

public Integer toInteger ()

Converts the counter value to its Integer form.

Returns
  • The Integer representation of the value.

public Long toLong ()

Converts the counter value to its Long form.

Returns
  • The Long representation of the value.

public SnmpOid toOid ()

Converts the counter value to its SnmpOid form.

Returns
  • The OID representation of the value.

public static SnmpOid toOid (long[] index, int start)

Extracts the counter from an index OID and returns its value converted as an SnmpOid.

Parameters
index The index array.
start The position in the index array.
Returns
  • The OID representing the counter value.
Throws
SnmpStatusException There is no counter value available at the start position.

public String toString ()

Converts the counter value to its String form.

Returns
  • The String representation of the value.