public final class S5bTransportMethod extends TransportMethod
<transport/> element in the urn:xmpp:jingle:transports:s5b:1 namespace.| Modifier and Type | Class and Description |
|---|---|
static class |
S5bTransportMethod.Candidate
The implementation of the
<candidate/> element in the urn:xmpp:jingle:transports:s5b:1 namespace. |
| Modifier and Type | Field and Description |
|---|---|
static String |
NAMESPACE
urn:xmpp:jingle:transports:s5b:1
|
| Constructor and Description |
|---|
S5bTransportMethod(String sessionId,
String dstaddr,
Socks5ByteStream.Mode mode,
Collection<S5bTransportMethod.Candidate> candidates) |
| Modifier and Type | Method and Description |
|---|---|
static S5bTransportMethod |
activated(String sid,
String cid)
Creates a transport method with a
<activated/> element. |
static int |
calculatePriority(S5bTransportMethod.Candidate.Type type,
int localPreference)
Gets the preferred priority.
|
static S5bTransportMethod |
candidateError(String sid)
Creates a transport method with a
<candidate-error/> element. |
static S5bTransportMethod |
candidateUsed(String sid,
String cid)
Creates a transport method with a
<candidate-used/> element. |
String |
getActivated()
Gets the id of the activated candidate.
|
List<S5bTransportMethod.Candidate> |
getCandidates()
Gets the candidates, i.e. stream hosts for the transport.
|
String |
getCandidateUsed()
Gets the id of the used candidate.
|
String |
getDstAddr()
Gets the DST.ADDR field for the SOCKS5 protocol.
|
Socks5ByteStream.Mode |
getMode()
Gets the mode.
|
String |
getSessionId()
Gets the session id.
|
boolean |
isCandidateError()
Indicates, if it's a candidate error.
|
boolean |
isProxyError()
Indicates, if it's a proxy error.
|
static S5bTransportMethod |
proxyError(String sid)
Creates a transport method with a
<proxy-error/> element. |
public static final String NAMESPACE
public S5bTransportMethod(String sessionId, String dstaddr, Socks5ByteStream.Mode mode, Collection<S5bTransportMethod.Candidate> candidates)
public static S5bTransportMethod candidateUsed(String sid, String cid)
<candidate-used/> element.sid - The session id.cid - The candidate id.public static S5bTransportMethod candidateError(String sid)
<candidate-error/> element.sid - The session id.public static S5bTransportMethod proxyError(String sid)
<proxy-error/> element.sid - The session id.public static S5bTransportMethod activated(String sid, String cid)
<activated/> element.sid - The session id.cid - The id of the activated candidate.public static int calculatePriority(S5bTransportMethod.Candidate.Type type, int localPreference)
type - The type.localPreference - The local preference, should be between 0 and 65535.public final String getDstAddr()
public final String getSessionId()
public final Socks5ByteStream.Mode getMode()
public final List<S5bTransportMethod.Candidate> getCandidates()
public final String getCandidateUsed()
public final String getActivated()
public final boolean isCandidateError()
public final boolean isProxyError()
Copyright © 2014–2017 XMPP.rocks. All rights reserved.