mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-12-12 14:01:08 +01:00
Introduce SmackParsingException
This commit is contained in:
parent
163ca2b009
commit
7dee3b88a2
54 changed files with 277 additions and 155 deletions
|
|
@ -17,9 +17,9 @@
|
|||
package org.jivesoftware.smackx.pubsub.provider;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.text.ParseException;
|
||||
|
||||
import org.jivesoftware.smack.packet.ExtensionElement;
|
||||
import org.jivesoftware.smack.parsing.SmackParsingException;
|
||||
import org.jivesoftware.smack.provider.ExtensionElementProvider;
|
||||
import org.jivesoftware.smack.provider.ProviderManager;
|
||||
import org.jivesoftware.smack.util.PacketParserUtils;
|
||||
|
|
@ -44,7 +44,7 @@ import org.xmlpull.v1.XmlPullParserException;
|
|||
public class ItemProvider extends ExtensionElementProvider<Item> {
|
||||
@Override
|
||||
public Item parse(XmlPullParser parser, int initialDepth)
|
||||
throws XmlPullParserException, IOException, ParseException {
|
||||
throws XmlPullParserException, IOException, SmackParsingException {
|
||||
String id = parser.getAttributeValue(null, "id");
|
||||
String node = parser.getAttributeValue(null, "node");
|
||||
String xmlns = parser.getNamespace();
|
||||
|
|
|
|||
|
|
@ -17,9 +17,9 @@
|
|||
package org.jivesoftware.smackx.pubsub.provider;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.text.ParseException;
|
||||
|
||||
import org.jivesoftware.smack.packet.IQ;
|
||||
import org.jivesoftware.smack.parsing.SmackParsingException;
|
||||
import org.jivesoftware.smack.provider.IQProvider;
|
||||
import org.jivesoftware.smack.util.PacketParserUtils;
|
||||
|
||||
|
|
@ -37,7 +37,7 @@ import org.xmlpull.v1.XmlPullParserException;
|
|||
*/
|
||||
public class PubSubProvider extends IQProvider<PubSub> {
|
||||
@Override
|
||||
public PubSub parse(XmlPullParser parser, int initialDepth) throws XmlPullParserException, IOException, ParseException {
|
||||
public PubSub parse(XmlPullParser parser, int initialDepth) throws XmlPullParserException, IOException, SmackParsingException {
|
||||
String namespace = parser.getNamespace();
|
||||
PubSubNamespace pubSubNamespace = PubSubNamespace.valueOfFromXmlns(namespace);
|
||||
PubSub pubsub = new PubSub(pubSubNamespace);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue