1
0
Fork 0
mirror of https://codeberg.org/Mercury-IM/Smack synced 2024-11-22 06:12:05 +01:00

[core] Remove @SuppressWarnings for parseContentDepthWithRoundtrip()

Also use the most specific return type in the method's signature.
This commit is contained in:
Florian Schmaus 2020-11-25 20:50:58 +01:00
parent ca497a2199
commit 02c9058c3d

View file

@ -299,7 +299,7 @@ public class PacketParserUtils {
*/ */
public static CharSequence parseContentDepth(XmlPullParser parser, int depth, boolean fullNamespaces) throws XmlPullParserException, IOException { public static CharSequence parseContentDepth(XmlPullParser parser, int depth, boolean fullNamespaces) throws XmlPullParserException, IOException {
if (parser.supportsRoundtrip()) { if (parser.supportsRoundtrip()) {
return parseContentDepthWithRoundtrip(parser, depth, fullNamespaces); return parseContentDepthWithRoundtrip(parser, depth);
} else { } else {
return parseContentDepthWithoutRoundtrip(parser, depth, fullNamespaces); return parseContentDepthWithoutRoundtrip(parser, depth, fullNamespaces);
} }
@ -368,8 +368,7 @@ public class PacketParserUtils {
return xml; return xml;
} }
@SuppressWarnings("UnusedVariable") private static XmlStringBuilder parseContentDepthWithRoundtrip(XmlPullParser parser, int depth)
private static CharSequence parseContentDepthWithRoundtrip(XmlPullParser parser, int depth, boolean fullNamespaces)
throws XmlPullParserException, IOException { throws XmlPullParserException, IOException {
XmlStringBuilder sb = new XmlStringBuilder(); XmlStringBuilder sb = new XmlStringBuilder();
XmlPullParser.Event event = parser.getEventType(); XmlPullParser.Event event = parser.getEventType();