com.esri.aims.mtier.model.axl
Class ErrorAndWarningException

java.lang.Object
  |
  +--java.lang.Throwable
        |
        +--java.lang.Exception
              |
              +--com.esri.xml.sax.SAXException
                    |
                    +--com.esri.aims.mtier.model.axl.ErrorAndWarningException
All Implemented Interfaces:
Serializable

public class ErrorAndWarningException
extends com.esri.xml.sax.SAXException

Thrown when an ERROR or WARNING response is received.

See Also:
Serialized Form

Constructor Summary
ErrorAndWarningException()
          Default constructor.
 
Method Summary
 void addError(int code, String message)
          Adds an error with given message string and code to the Exception.
 void addWarning(int code, String message)
          Adds an warning with given message and code to the Exception.
 boolean containsErrorCode(int code)
          Returns true if the error code exists, false array otherwise.
 boolean containsErrorMessage(String message)
          Returns true if the error message exists, false otherwise.
 boolean containsWarningCode(int code)
          Returns true if the warning code exists, false otherwise.
 boolean containsWarningMessage(String message)
          Returns true if the warning message exists, false otherwise.
 int getErrorCodeAt(int index)
          Returns the error code at the given index.
 int getErrorCount()
          Returns the number of errors.
 String getErrorMessageAt(int index)
          Returns the error message at the given index.
 int getWarningCodeAt(int index)
          Returns the warning code at the given index.
 int getWarningCount()
          Returns the number of warnings.
 String getWarningMessageAt(int index)
          Returns the warning message at the given index.
 boolean hasErrors()
          Returns true if errors were found.
 boolean hasWarnings()
          Returns true if the WARNINGs were found.
 
Methods inherited from class com.esri.xml.sax.SAXException
getException, getMessage, toString
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ErrorAndWarningException

public ErrorAndWarningException()
Default constructor.

Method Detail

addError

public void addError(int code,
                     String message)
Adds an error with given message string and code to the Exception.

Parameters:
code - the error code being returned.
message - the error message being returned.

addWarning

public void addWarning(int code,
                       String message)
Adds an warning with given message and code to the Exception.

Parameters:
code - The warning code being returned.
message - The warning message being returned.

hasErrors

public boolean hasErrors()
Returns true if errors were found.


getErrorCount

public int getErrorCount()
Returns the number of errors.


getErrorCodeAt

public int getErrorCodeAt(int index)
Returns the error code at the given index.


getErrorMessageAt

public String getErrorMessageAt(int index)
Returns the error message at the given index.


containsErrorCode

public boolean containsErrorCode(int code)
Returns true if the error code exists, false array otherwise.


containsErrorMessage

public boolean containsErrorMessage(String message)
Returns true if the error message exists, false otherwise.


hasWarnings

public boolean hasWarnings()
Returns true if the WARNINGs were found.


getWarningCount

public int getWarningCount()
Returns the number of warnings.


getWarningCodeAt

public int getWarningCodeAt(int index)
Returns the warning code at the given index.


getWarningMessageAt

public String getWarningMessageAt(int index)
Returns the warning message at the given index.


containsWarningCode

public boolean containsWarningCode(int code)
Returns true if the warning code exists, false otherwise.


containsWarningMessage

public boolean containsWarningMessage(String message)
Returns true if the warning message exists, false otherwise.