Class SmiParseException

java.lang.Object
java.lang.Throwable
java.lang.Exception
com.snmp4j.smi.SmiParseException
All Implemented Interfaces:
Serializable

public final class SmiParseException extends Exception
The SmiParseException provides information about violations of the Structure of Management Information (SMI) v1 or v2 standards. Per MIB specification file, there might be more than one error reported by this exception.
Author:
Frank Fock
See Also:
Serialized Form
  • Constructor Details

    • SmiParseException

      public SmiParseException(List<SmiError> errors)
      Creates a SmiParseException from a list of SmiErrors.
      Parameters:
      errors - the parse errors collected until bailing out with this exception.
  • Method Details

    • getMessage

      public String getMessage()
      Gets the error message for all errors found in a MIB specification. Each error is separated by a double new line.
      Overrides:
      getMessage in class Throwable
      Returns:
      the error message text.
    • getErrorList

      public List<SmiError> getErrorList()
      Gets the list of SmiErrors.
      Returns:
      the List of SmiErrors for this MIB specification file.
    • toString

      public String toString()
      Overrides:
      toString in class Throwable