public class HostCandidate extends LocalCandidate
At this point this class only supports UDP candidates. Implementation of support for other transport protocols should mean that this class should become abstract and some transport specific components like to socket for example should be brought down the inheritance chain.
Modifier and Type | Field and Description |
---|---|
private IceSocketWrapper |
socket
If this is a local candidate the field contains the socket that is
actually associated with the candidate.
|
MAX_LOCAL_PREFERENCE, MAX_TYPE_PREFERENCE, MIN_LOCAL_PREFERENCE, MIN_TYPE_PREFERENCE, priority
Constructor and Description |
---|
HostCandidate(IceSocketWrapper socket,
Component parentComponent)
Creates a HostCandidate for the specified transport address.
|
HostCandidate(IceSocketWrapper socket,
Component parentComponent,
Transport transport)
Creates a HostCandidate for the specified transport address.
|
HostCandidate(TransportAddress transportAddress,
Component parentComponent)
Creates a HostCandidate for the specified transport address.
|
Modifier and Type | Method and Description |
---|---|
protected StunDatagramPacketFilter |
createStunDatagramPacketFilter(TransportAddress serverAddress)
Creates a new StunDatagramPacketFilter which is to capture STUN
messages and make them available to the DatagramSocket returned
by
LocalCandidate.getStunSocket(TransportAddress) . |
IceSocketWrapper |
getCandidateIceSocketWrapper()
SHOULD NOT be used outside ice4j.
|
findRelatedCandidate, free, getCandidateIceSocketWrapper, getDatagramSocket, getExtendedType, getIceSocketWrapper, getSocket, getStunSocket, getStunStack, getUfrag, isDefault, isSSL, setExtendedType, setSSL, setUfrag
canReach, compareTo, computeGTalkPriority, computeGTalkPriorityForType, computePriority, computePriorityForType, equals, getBase, getDefaultPreference, getFoundation, getHostAddress, getMappedAddress, getParentComponent, getPriority, getReflexiveAddress, getRelatedAddress, getRelatedCandidate, getRelayedAddress, getRelayServerAddress, getStunServerAddress, getTcpType, getTransport, getTransportAddress, getType, hashCode, isVirtual, setBase, setCandidateType, setFoundation, setMappedAddress, setRelayServerAddress, setStunServerAddress, setTcpType, setVirtual, toShortString, toString
private final IceSocketWrapper socket
public HostCandidate(IceSocketWrapper socket, Component parentComponent)
socket
- the DatagramSocket
that communication associated
with this Candidate will be going through.parentComponent
- the Component that this candidate
belongs to.public HostCandidate(TransportAddress transportAddress, Component parentComponent)
transportAddress
- the transport address for the new
HostCandidate.parentComponent
- the Component that this candidate
belongs to.public HostCandidate(IceSocketWrapper socket, Component parentComponent, Transport transport)
socket
- the DatagramSocket
that communication associated
with this Candidate will be going through.parentComponent
- the Component that this candidate
belongs to.transport
- transport protocol usedprotected StunDatagramPacketFilter createStunDatagramPacketFilter(TransportAddress serverAddress)
LocalCandidate.getStunSocket(TransportAddress)
.createStunDatagramPacketFilter
in class LocalCandidate
serverAddress
- the address of the source we'd like to receive
packets from or null if we'd like to intercept all STUN packetsLocalCandidate.getStunSocket(TransportAddress)
LocalCandidate.createStunDatagramPacketFilter(TransportAddress)
public IceSocketWrapper getCandidateIceSocketWrapper()
getCandidateIceSocketWrapper
in class LocalCandidate
IceSocketWrapper
instance, if any, associated with
this candidate. Note that this IS NOT the instance which should be used
for reading and writing by the application, and SHOULD NOT be used from
outside ice4j (even if a subclass exposes it as public). Also see
LocalCandidate.getIceSocketWrapper()
.Copyright © 2018. All rights reserved.