Package com.opencloud.javax.sip
Class LazyParsingException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- com.opencloud.javax.sip.LazyParsingException
-
- All Implemented Interfaces:
Serializable
public class LazyParsingException extends RuntimeException
Thrown if the underlying stack supports lazy parsing, and a header failed to parse when the application requested the header value.This is an unchecked exception so that apps already written using JAIN SIP will still work.
Applications that catch these exceptions can try to decode the offending header themselves by using the
getUnparsedHeaderLine
method to get the unparsed string value of the header.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description LazyParsingException(String message, String unparsedHeaderLine)
LazyParsingException(String message, String headerName, String unparsedHeaderLine)
LazyParsingException(String message, String headerName, Throwable cause, String unparsedHeaderLine)
LazyParsingException(String message, Throwable cause, String unparsedHeaderLine)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getHeaderName()
Get the name of the header that failed to parse.String
getMessage()
String
getUnparsedHeaderLine()
Get the content of the header line that failed to parseboolean
hasHeaderName()
void
setHeaderName(String name)
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Method Detail
-
hasHeaderName
public boolean hasHeaderName()
-
getHeaderName
public String getHeaderName()
Get the name of the header that failed to parse.- Returns:
- the header name, or null if not specified.
-
setHeaderName
public void setHeaderName(String name)
-
getUnparsedHeaderLine
public String getUnparsedHeaderLine()
Get the content of the header line that failed to parse- Returns:
- the content of the header line that failed to parse
-
getMessage
public String getMessage()
- Overrides:
getMessage
in classThrowable
-
-