net.percederberg.mibble
Class MibValueSymbol

java.lang.Object
  extended bynet.percederberg.mibble.MibSymbol
      extended bynet.percederberg.mibble.MibValueSymbol

public class MibValueSymbol
extends MibSymbol

A MIB value symbol. This class holds information relevant to a MIB value assignment, i.e. a type and a value. Normally the value is an object identifier.

Since:
2.0

Constructor Summary
MibValueSymbol(FileLocation location, Mib mib, java.lang.String name, MibType type, MibValue value)
          Creates a new value symbol.
 
Method Summary
 MibType getType()
          Returns the symbol type.
 MibValue getValue()
          Returns the symbol value.
 void initialize(MibLoaderLog log)
          Initializes the MIB symbol.
 java.lang.String toString()
          Returns a string representation of this object.
 
Methods inherited from class net.percederberg.mibble.MibSymbol
getLocation, getMib, getName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MibValueSymbol

public MibValueSymbol(FileLocation location,
                      Mib mib,
                      java.lang.String name,
                      MibType type,
                      MibValue value)
Creates a new value symbol.

NOTE: This is an internal constructor that should only be called by the MIB loader.

Parameters:
location - the symbol location
mib - the symbol MIB file
name - the symbol name
type - the symbol type
value - the symbol value
Since:
2.2
Method Detail

initialize

public void initialize(MibLoaderLog log)
                throws MibException
Initializes the MIB symbol. This will remove all levels of indirection present, such as references to types or values. No information is lost by this operation. This method may modify this object as a side-effect.

NOTE: This is an internal method that should only be called by the MIB loader.

Specified by:
initialize in class MibSymbol
Parameters:
log - the MIB loader log
Throws:
MibException - if an error was encountered during the initialization

getType

public MibType getType()
Returns the symbol type.

Returns:
the symbol type

getValue

public MibValue getValue()
Returns the symbol value.

Returns:
the symbol value

toString

public java.lang.String toString()
Returns a string representation of this object.

Returns:
a string representation of this object