de.smartics.exceptions.i18n.message
Class ParseException

Package class diagram package ParseException
java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by de.smartics.exceptions.AbstractCoreRuntimeException
                  extended by de.smartics.exceptions.i18n.AbstractLocalizedRuntimeException
                      extended by de.smartics.exceptions.i18n.message.ParseException
All Implemented Interfaces:
CoreException, LocalizedException, Serializable

public class ParseException
     
     
extends AbstractLocalizedRuntimeException

This exception is thrown if a string cannot be parsed because information is missing or the format syntax is violated.

See Also:
Serialized Form

Field Summary
protected  int index
          The index within the input string where the parsing error occurred.
protected  String input
          The input that cannot be parsed.
 
Fields inherited from class de.smartics.exceptions.i18n.AbstractLocalizedRuntimeException
localizedInfo
 
Fields inherited from class de.smartics.exceptions.AbstractCoreRuntimeException
info
 
Constructor Summary
  ParseException(ParseExceptionCode code, String input, int index)
          Constructor.
  ParseException(ParseExceptionCode code, String bundleBaseName, String input, int index)
          Constructor.
protected ParseException(Throwable cause, ParseExceptionCode code, String input, int index)
          Constructor.
protected ParseException(Throwable cause, ParseExceptionCode code, String bundleBaseName, String input, int index)
          Constructor.
 
Method Summary
 int getIndex()
          Returns the index within the input string where the parsing error occurred.
 String getInput()
          Returns the input that cannot be parsed.
 
Methods inherited from class de.smartics.exceptions.i18n.AbstractLocalizedRuntimeException
createMessages, createMessages, getBundleBaseName, getCauseTrail, getCauseTrail, getLocalizedMessage, getLocalizedMessage, getLocalizedMessage, getLocalizedMessage, getMessage, getMessage, getMessage, getMessages, getMessages, getResourceKey, toString
 
Methods inherited from class de.smartics.exceptions.AbstractCoreRuntimeException
getCause, getCode, getId, getTime, truncateCause
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface de.smartics.exceptions.CoreException
getCause, getCode, getId, getStackTrace, getTime, setStackTrace, truncateCause
 

Field Detail

input

@MessageParam(value="0")
protected final String input
The input that cannot be parsed.


index

@MessageParam(value="1")
protected final int index
The index within the input string where the parsing error occurred.

Constructor Detail

ParseException

public ParseException(ParseExceptionCode code,
                      String bundleBaseName,
                      String input,
                      int index)
Constructor.

Parameters:
code - the error or exception code of the exception.
bundleBaseName - the fully qualified name of the bundle to use.
input - the input that cannot be parsed.
index - the index within the input string where the parsing error occurred.
See Also:
ParseException(Throwable,ParseExceptionCode,java.lang.String,java.lang.String,int)

ParseException

public ParseException(ParseExceptionCode code,
                      String input,
                      int index)
Constructor.

Parameters:
code - the error or exception code of the exception.
input - the input that cannot be parsed.
index - the index within the input string where the parsing error occurred.
See Also:
ParseException(ParseExceptionCode,String,java.lang.String,int)

ParseException

protected ParseException(Throwable cause,
                         ParseExceptionCode code,
                         String bundleBaseName,
                         String input,
                         int index)
Constructor.

Parameters:
cause - the cause (which is saved for later retrieval by the AbstractCoreRuntimeException.getCause() method). (A null value is permitted, and indicates that the cause is nonexistent or unknown.)
code - the error or exception code of the exception.
bundleBaseName - the fully qualified name of the bundle to use.
input - the input that cannot be parsed.
index - the index within the input string where the parsing error occurred.
See Also:
AbstractLocalizedRuntimeException.AbstractLocalizedRuntimeException(Throwable,de.smartics.exceptions.core.Code,String)

ParseException

protected ParseException(Throwable cause,
                         ParseExceptionCode code,
                         String input,
                         int index)
Constructor.

Parameters:
cause - the cause (which is saved for later retrieval by the AbstractCoreRuntimeException.getCause() method). (A null value is permitted, and indicates that the cause is nonexistent or unknown.)
code - the error or exception code of the exception.
input - the input that cannot be parsed.
index - the index within the input string where the parsing error occurred.
See Also:
ParseException(Throwable,ParseExceptionCode,String,String,int)
Method Detail

getInput

public String getInput()
Returns the input that cannot be parsed.

Returns:
the input that cannot be parsed.

getIndex

public int getIndex()
Returns the index within the input string where the parsing error occurred.

Returns:
the index within the input string where the parsing error occurred.


Copyright © 2007-2013 Kronseder & Reiner GmbH - smartics. All Rights Reserved.