mirror of
https://github.com/vanitasvitae/Smack.git
synced 2025-12-14 15:01:07 +01:00
Make Provider.parse() just throw Exception
instead of throwing XmlPullParserException, IOException and SmackException. Add a guard to AbstractXMPPConnection.processPacket() to always re-throw RuntimeExceptions.
This commit is contained in:
parent
4d9bd6f216
commit
bc093b620d
29 changed files with 63 additions and 156 deletions
|
|
@ -17,7 +17,6 @@
|
|||
|
||||
package org.jivesoftware.smackx.xdata.provider;
|
||||
|
||||
import org.jivesoftware.smack.SmackException;
|
||||
import org.jivesoftware.smack.provider.ExtensionElementProvider;
|
||||
import org.jivesoftware.smack.roster.packet.RosterPacket;
|
||||
import org.jivesoftware.smack.roster.provider.RosterPacketProvider;
|
||||
|
|
@ -42,8 +41,8 @@ import java.util.List;
|
|||
public class DataFormProvider extends ExtensionElementProvider<DataForm> {
|
||||
|
||||
@Override
|
||||
public DataForm parse(XmlPullParser parser, int initialDepth) throws XmlPullParserException, IOException,
|
||||
SmackException {
|
||||
public DataForm parse(XmlPullParser parser, int initialDepth) throws
|
||||
Exception {
|
||||
DataForm.Type dataFormType = DataForm.Type.fromString(parser.getAttributeValue("", "type"));
|
||||
DataForm dataForm = new DataForm(dataFormType);
|
||||
outerloop: while (true) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue