Class JingleReason
- java.lang.Object
-
- org.jivesoftware.smackx.jingle.element.JingleReason
-
- All Implemented Interfaces:
Element,FullyQualifiedElement,NamedElement,XmlLangElement
- Direct Known Subclasses:
JingleReason.AlternativeSession
public class JingleReason extends java.lang.Object implements FullyQualifiedElement
The Jingle 'reason' element.- See Also:
- XEP-0166 ยง 7.4
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classJingleReason.AlternativeSessionstatic classJingleReason.Reason
-
Field Summary
Fields Modifier and Type Field Description static JingleReasonBusystatic JingleReasonCancelstatic JingleReasonConnectivityErrorstatic JingleReasonDeclinestatic java.lang.StringELEMENTstatic JingleReasonExpiredstatic JingleReasonFailedApplicationstatic JingleReasonFailedTransportstatic JingleReasonGeneralErrorstatic JingleReasonGonestatic JingleReasonIncompatibleParametersstatic JingleReasonMediaErrorstatic java.lang.StringNAMESPACEprotected JingleReason.Reasonreasonstatic JingleReasonSecurityErrorstatic JingleReasonSuccessstatic java.lang.StringTEXT_ELEMENTstatic JingleReasonTimeoutstatic JingleReasonUnsupportedApplicationsstatic JingleReasonUnsupportedTransports
-
Constructor Summary
Constructors Constructor Description JingleReason(JingleReason.Reason reason)JingleReason(JingleReason.Reason reason, java.lang.String text, ExtensionElement element)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static JingleReason.AlternativeSessionAlternativeSession(java.lang.String sessionId)JingleReason.ReasonasEnum()ExtensionElementgetElement()An optional element that provides more detailed machine-readable information about the reason for the action.java.lang.StringgetElementName()Returns the root element name.java.lang.StringgetNamespace()Returns the root element XML namespace.java.lang.StringgetText()An optional text that provides human-readable information about the reason for the action.XmlStringBuildertoXML(XmlEnvironment enclosingXmlEnvironment)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.jivesoftware.smack.packet.FullyQualifiedElement
getLanguage, getQName
-
-
-
-
Field Detail
-
ELEMENT
public static final java.lang.String ELEMENT
- See Also:
- Constant Field Values
-
NAMESPACE
public static final java.lang.String NAMESPACE
- See Also:
- Constant Field Values
-
TEXT_ELEMENT
public static final java.lang.String TEXT_ELEMENT
- See Also:
- Constant Field Values
-
Busy
public static final JingleReason Busy
-
Cancel
public static final JingleReason Cancel
-
ConnectivityError
public static final JingleReason ConnectivityError
-
Decline
public static final JingleReason Decline
-
Expired
public static final JingleReason Expired
-
FailedApplication
public static final JingleReason FailedApplication
-
FailedTransport
public static final JingleReason FailedTransport
-
GeneralError
public static final JingleReason GeneralError
-
Gone
public static final JingleReason Gone
-
IncompatibleParameters
public static final JingleReason IncompatibleParameters
-
MediaError
public static final JingleReason MediaError
-
SecurityError
public static final JingleReason SecurityError
-
Success
public static final JingleReason Success
-
Timeout
public static final JingleReason Timeout
-
UnsupportedApplications
public static final JingleReason UnsupportedApplications
-
UnsupportedTransports
public static final JingleReason UnsupportedTransports
-
reason
protected final JingleReason.Reason reason
-
-
Constructor Detail
-
JingleReason
public JingleReason(JingleReason.Reason reason)
-
JingleReason
public JingleReason(JingleReason.Reason reason, java.lang.String text, ExtensionElement element)
-
-
Method Detail
-
AlternativeSession
public static JingleReason.AlternativeSession AlternativeSession(java.lang.String sessionId)
-
getElementName
public java.lang.String getElementName()
Description copied from interface:NamedElementReturns the root element name.- Specified by:
getElementNamein interfaceNamedElement- Returns:
- the element name.
-
getNamespace
public java.lang.String getNamespace()
Description copied from interface:FullyQualifiedElementReturns the root element XML namespace.- Specified by:
getNamespacein interfaceFullyQualifiedElement- Returns:
- the namespace.
-
getText
public java.lang.String getText()
An optional text that provides human-readable information about the reason for the action.- Returns:
- a human-readable text with information regarding this reason or
null. - Since:
- 4.4.5
-
getElement
public ExtensionElement getElement()
An optional element that provides more detailed machine-readable information about the reason for the action.- Returns:
- an element with machine-readable information about this reason or
null. - Since:
- 4.4.5
-
toXML
public XmlStringBuilder toXML(XmlEnvironment enclosingXmlEnvironment)
-
asEnum
public JingleReason.Reason asEnum()
-
-