@NotThreadSafe public class StreamError extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
StreamError.Condition
Type-safe enumeration for the error condition.
|
| Constructor and Description |
|---|
StreamError(org.dom4j.Element element)
Constructs a new StreamError using an existing Element.
|
StreamError(StreamError.Condition condition)
Construcs a new StreamError with the specified condition.
|
StreamError(StreamError.Condition condition,
String text)
Constructs a new StreamError with the specified condition and error text.
|
StreamError(StreamError.Condition condition,
String text,
String language)
Constructs a new StreamError with the specified condition and error text.
|
| Modifier and Type | Method and Description |
|---|---|
StreamError.Condition |
getCondition()
Returns the error condition.
|
org.dom4j.Element |
getElement()
Returns the DOM4J Element that backs the error.
|
String |
getText()
Returns a text description of the error, or null if there
is no text description.
|
String |
getTextLanguage()
Returns the text description's language code, or null if there
is no language code associated with the description text.
|
void |
setCondition(StreamError.Condition condition)
Sets the error condition.
|
void |
setText(String text)
Sets the text description of the error.
|
void |
setText(String text,
String language)
Sets the text description of the error.
|
String |
toString() |
String |
toXML()
Returns the textual XML representation of this stream error.
|
public StreamError(StreamError.Condition condition)
condition - the error condition.public StreamError(StreamError.Condition condition, String text)
condition - the error condition.text - the text description of the error.public StreamError(StreamError.Condition condition, String text, String language)
condition - the error condition.text - the text description of the error.language - the language code of the error description (e.g. "en").public StreamError(org.dom4j.Element element)
element - the stream error Element.public StreamError.Condition getCondition()
StreamError.Conditionpublic void setCondition(StreamError.Condition condition)
condition - the error condition.StreamError.Conditionpublic String getText()
public void setText(String text)
text - the text description of the error.public void setText(String text, String language)
text - the text description of the error.language - the language code of the description, or null to specify
no language code.public String getTextLanguage()
public org.dom4j.Element getElement()
public String toXML()
Copyright © 2009–2017 Ignite Realtime. All rights reserved.