Search in sources :

Example 1 with DataFormsXmlElement

use of org.jivesoftware.smackx.xmlelement.element.DataFormsXmlElement in project Smack by igniterealtime.

the class DataFormsXmlElementProvider method parse.

@Override
public DataFormsXmlElement parse(XmlPullParser parser, int initialDepth, XmlEnvironment xmlEnvironment) throws IOException, XmlPullParserException, SmackParsingException {
    XmlPullParser.TagEvent tagEvent = parser.nextTag();
    final StandardExtensionElement standardExtensionElement;
    if (tagEvent == XmlPullParser.TagEvent.START_ELEMENT) {
        standardExtensionElement = StandardExtensionElementProvider.INSTANCE.parse(parser);
    } else {
        standardExtensionElement = null;
    }
    return new DataFormsXmlElement(standardExtensionElement);
}
Also used : StandardExtensionElement(org.jivesoftware.smack.packet.StandardExtensionElement) XmlPullParser(org.jivesoftware.smack.xml.XmlPullParser) DataFormsXmlElement(org.jivesoftware.smackx.xmlelement.element.DataFormsXmlElement)

Aggregations

StandardExtensionElement (org.jivesoftware.smack.packet.StandardExtensionElement)1 XmlPullParser (org.jivesoftware.smack.xml.XmlPullParser)1 DataFormsXmlElement (org.jivesoftware.smackx.xmlelement.element.DataFormsXmlElement)1