net.percederberg.mibble
Interface MibType

All Known Implementing Classes:
BitSetType, BooleanType, ChoiceType, ElementType, IntegerType, NullType, ObjectIdentifierType, RealType, SequenceOfType, SequenceType, SnmpAgentCapabilities, SnmpModuleCompliance, SnmpModuleIdentity, SnmpNotificationGroup, SnmpNotificationType, SnmpObjectGroup, SnmpObjectIdentity, SnmpObjectType, SnmpTextualConvention, SnmpTrapType, StringType, TypeReference

public interface MibType

A MIB type.

Since:
2.0

Method Summary
 MibType initialize(MibLoaderLog log)
          Initializes the MIB type.
 boolean isCompatible(MibValue value)
          Checks if the specified value is compatible with this type.
 

Method Detail

initialize

public MibType initialize(MibLoaderLog log)
                   throws MibException
Initializes the MIB type. This will remove all levels of indirection present, such as references to other types, and returns the basic type. No type 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
Returns:
the basic MIB type
Throws:
MibException - if an error was encountered during the initialization

isCompatible

public boolean isCompatible(MibValue value)
Checks if the specified value is compatible with this type. A value is compatible if it has a type that matches this one and a value that satisfies all constraints.

Parameters:
value - the value to check
Returns:
true if the value is compatible, or false otherwise