mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2025-09-09 10:19:41 +02:00
Rename AbstractIqBuilder subclasses to their designated names
This commit is contained in:
parent
6e32305987
commit
69767e9538
16 changed files with 58 additions and 64 deletions
|
@ -26,7 +26,7 @@ import java.util.Set;
|
|||
|
||||
import org.jivesoftware.smack.XMPPConnection;
|
||||
import org.jivesoftware.smack.packet.IQ;
|
||||
import org.jivesoftware.smack.packet.IqBuilder;
|
||||
import org.jivesoftware.smack.packet.IqData;
|
||||
import org.jivesoftware.smack.util.EqualsUtil;
|
||||
import org.jivesoftware.smack.util.HashCode;
|
||||
import org.jivesoftware.smack.util.StringUtils;
|
||||
|
@ -148,7 +148,7 @@ public class DiscoverInfo extends IQ implements DiscoverInfoView, TypedCloneable
|
|||
*
|
||||
* @param feature the future.
|
||||
* @return true if the feature is new.
|
||||
* @deprecated use {@link DiscoverInfoBuilder#addFeature(Feature)} instead.
|
||||
* @deprecated use {@link DiscoverInfoBuilder#addFeature(DiscoverInfo.Feature)} instead.
|
||||
*/
|
||||
@Deprecated
|
||||
// TODO: Remove in Smack 4.5.
|
||||
|
@ -170,7 +170,7 @@ public class DiscoverInfo extends IQ implements DiscoverInfoView, TypedCloneable
|
|||
* Adds a new identity of the requested entity to the discovered information.
|
||||
*
|
||||
* @param identity the discovered entity's identity
|
||||
* @deprecated use {@link DiscoverInfoBuilder#addIdentity(Identity)} instead.
|
||||
* @deprecated use {@link DiscoverInfoBuilder#addIdentity(DiscoverInfo.Identity)} instead.
|
||||
*/
|
||||
@Deprecated
|
||||
// TODO: Remove in Smack 4.5.
|
||||
|
@ -313,7 +313,7 @@ public class DiscoverInfo extends IQ implements DiscoverInfoView, TypedCloneable
|
|||
return new DiscoverInfoBuilder(connection);
|
||||
}
|
||||
|
||||
public static DiscoverInfoBuilder builder(IqBuilder iqData) {
|
||||
public static DiscoverInfoBuilder builder(IqData iqData) {
|
||||
return new DiscoverInfoBuilder(iqData);
|
||||
}
|
||||
|
||||
|
|
|
@ -23,12 +23,12 @@ import java.util.List;
|
|||
import org.jivesoftware.smack.XMPPConnection;
|
||||
import org.jivesoftware.smack.packet.IQ;
|
||||
import org.jivesoftware.smack.packet.IqBuilder;
|
||||
import org.jivesoftware.smack.packet.IqBuilderWithBuild;
|
||||
import org.jivesoftware.smack.packet.IqData;
|
||||
|
||||
import org.jivesoftware.smackx.disco.packet.DiscoverInfo.Feature;
|
||||
import org.jivesoftware.smackx.disco.packet.DiscoverInfo.Identity;
|
||||
|
||||
public class DiscoverInfoBuilder extends IqBuilderWithBuild<DiscoverInfoBuilder, DiscoverInfo>
|
||||
public class DiscoverInfoBuilder extends IqBuilder<DiscoverInfoBuilder, DiscoverInfo>
|
||||
implements DiscoverInfoView {
|
||||
|
||||
private final List<Feature> features = new ArrayList<>();
|
||||
|
@ -36,7 +36,7 @@ public class DiscoverInfoBuilder extends IqBuilderWithBuild<DiscoverInfoBuilder,
|
|||
|
||||
private String node;
|
||||
|
||||
DiscoverInfoBuilder(IqBuilder iqCommon) {
|
||||
DiscoverInfoBuilder(IqData iqCommon) {
|
||||
super(iqCommon);
|
||||
}
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@ package org.jivesoftware.smackx.disco.provider;
|
|||
|
||||
import java.io.IOException;
|
||||
|
||||
import org.jivesoftware.smack.packet.IqBuilder;
|
||||
import org.jivesoftware.smack.packet.IqData;
|
||||
import org.jivesoftware.smack.packet.XmlEnvironment;
|
||||
import org.jivesoftware.smack.parsing.SmackParsingException;
|
||||
import org.jivesoftware.smack.provider.IqProvider;
|
||||
|
@ -39,7 +39,7 @@ import org.jivesoftware.smackx.disco.packet.DiscoverInfoBuilder;
|
|||
public class DiscoverInfoProvider extends IqProvider<DiscoverInfo> {
|
||||
|
||||
@Override
|
||||
public DiscoverInfo parse(XmlPullParser parser, int initialDepth, IqBuilder iqData, XmlEnvironment xmlEnvironment)
|
||||
public DiscoverInfo parse(XmlPullParser parser, int initialDepth, IqData iqData, XmlEnvironment xmlEnvironment)
|
||||
throws XmlPullParserException, IOException, SmackParsingException {
|
||||
DiscoverInfoBuilder discoverInfoBuilder = DiscoverInfo.builder(iqData);
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ package org.jivesoftware.smackx.ping.packet;
|
|||
|
||||
import org.jivesoftware.smack.XMPPConnection;
|
||||
import org.jivesoftware.smack.packet.IQ;
|
||||
import org.jivesoftware.smack.packet.IqBuilder;
|
||||
import org.jivesoftware.smack.packet.IqData;
|
||||
import org.jivesoftware.smack.packet.SimpleIQ;
|
||||
|
||||
import org.jxmpp.jid.Jid;
|
||||
|
@ -39,14 +39,14 @@ public class Ping extends SimpleIQ {
|
|||
}
|
||||
|
||||
public Ping(XMPPConnection connection, Jid to) {
|
||||
this(connection.getStanzaFactory().buildIqStanza(), to);
|
||||
this(connection.getStanzaFactory().buildIqData(), to);
|
||||
}
|
||||
|
||||
public Ping(IqBuilder iqBuilder, Jid to) {
|
||||
public Ping(IqData iqBuilder, Jid to) {
|
||||
super(iqBuilder.to(to).ofType(IQ.Type.get), ELEMENT, NAMESPACE);
|
||||
}
|
||||
|
||||
public Ping(IqBuilder iqBuilder) {
|
||||
public Ping(IqData iqBuilder) {
|
||||
super(iqBuilder, ELEMENT, NAMESPACE);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue