javax.sdp
Class SdpParseException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by javax.sdp.SdpException
              extended by javax.sdp.SdpParseException
All Implemented Interfaces:
Serializable

public class SdpParseException
extends SdpException

The SdpParseException encapsulates the information thrown when an error occurs during SDP parsing.

Version:
1.0
Author:
deruelle
See Also:
Serialized Form

Constructor Summary
SdpParseException(int lineNumber, int charOffset, String message)
          Constructs a new SdpParseException when the parser needs to throw an exception indicating a parsing failure.
SdpParseException(int lineNumber, int charOffset, String message, Throwable rootCause)
          Constructs a new SdpParseException when the parser needs to throw an exception indicating a parsing failure.
 
Method Summary
 int getCharOffset()
          Returns the char offset where the error occured.
 int getLineNumber()
          Returns the line number where the error occured
 String getMessage()
          Returns the message stored when the exception was created.
 
Methods inherited from class javax.sdp.SdpException
getRootCause
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SdpParseException

public SdpParseException(int lineNumber,
                         int charOffset,
                         String message,
                         Throwable rootCause)
Constructs a new SdpParseException when the parser needs to throw an exception indicating a parsing failure.

Parameters:
lineNumber - SDP line number that caused the exception.
charOffset - offset of the characeter that caused the exception.
message - a String containing the text of the exception message
rootCause - the Throwable exception that interfered with the Codelet's normal operation, making this Codelet exception necessary.

SdpParseException

public SdpParseException(int lineNumber,
                         int charOffset,
                         String message)
Constructs a new SdpParseException when the parser needs to throw an exception indicating a parsing failure.

Parameters:
lineNumber - SDP line number that caused the exception.
charOffset - offset of the characeter that caused the exception.
message - a String containing the text of the exception message
Method Detail

getLineNumber

public int getLineNumber()
Returns the line number where the error occured

Returns:
the line number where the error occured

getCharOffset

public int getCharOffset()
Returns the char offset where the error occured.

Returns:
the char offset where the error occured.

getMessage

public String getMessage()
Returns the message stored when the exception was created.

Overrides:
getMessage in class Throwable
Returns:
the message stored when the exception was created.


Copyright © 2012. All Rights Reserved.