net.percederberg.mibble
Class MibSymbol

java.lang.Object
  extended bynet.percederberg.mibble.MibSymbol
Direct Known Subclasses:
MibTypeSymbol, MibValueSymbol

public abstract class MibSymbol
extends java.lang.Object

A MIB symbol. This is the base class for all symbols in a MIB file. Each symbol is typically identified by it's name, which must be unique within the MIB file. All symbols also have a data type.

Since:
2.0

Constructor Summary
MibSymbol(FileLocation location, java.lang.String name)
          Creates a new symbol with the specified name.
 
Method Summary
 FileLocation getLocation()
          Returns the file location.
 java.lang.String getName()
          Returns the symbol name.
abstract  void initialize(MibLoaderLog log)
          Initializes the MIB symbol.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MibSymbol

public MibSymbol(FileLocation location,
                 java.lang.String name)
Creates a new symbol with the specified name.

Parameters:
name - the symbol name
location - the symbol location
Method Detail

initialize

public abstract 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, and will be called by the MIB loader.

Parameters:
log - the MIB loader log
Throws:
MibException - if an error was encountered during the initialization

getLocation

public FileLocation getLocation()
Returns the file location.

Returns:
the file location

getName

public java.lang.String getName()
Returns the symbol name.

Returns:
the symbol name