|
Jitsi: the OpenSource Java VoIP and Instant Messaging client. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.java.sip.communicator.service.protocol.media.TransportManager<U>
U - the peer extension class like for example CallPeerSipImpl
or CallPeerJabberImplpublic abstract class TransportManager<U extends MediaAwareCallPeer<?,?,?>>
TransportManagers are responsible for allocating ports, gathering local candidates and managing ICE whenever we are using it.
| Constructor Summary | |
|---|---|
protected |
TransportManager(U callPeer)
Creates a new instance of this transport manager, binding it to the specified peer. |
| Method Summary | |
|---|---|
void |
closeStreamConnector(MediaType mediaType)
Closes the existing StreamConnector, if any, associated with a specific MediaType and removes its reference from this TransportManager. |
protected void |
closeStreamConnector(MediaType mediaType,
StreamConnector streamConnector)
Closes a specific StreamConnector associated with a specific MediaType. |
protected StreamConnector |
createStreamConnector(MediaType mediaType)
Creates a media StreamConnector. |
U |
getCallPeer()
Returns the MediaAwareCallPeer that this transport manager is
serving. |
abstract String |
getICECandidateExtendedType()
Returns the extended type of the candidate selected if this transport manager is using ICE. |
static String |
getICECandidateExtendedType(org.ice4j.ice.Agent iceAgent)
Returns the ICE candidate extended type selected by the given agent. |
abstract String |
getICEState()
Returns the current state of ICE processing. |
protected abstract InetAddress |
getIntendedDestination(U peer)
Returns the InetAddress that is most likely to be used as a next hop when contacting the specified destination. |
InetAddress |
getLastUsedLocalHost()
Returns the InetAddress that we are using in one of our StreamConnectors or, in case we don't have any connectors yet the address returned by the our network address manager as the best local address to use when contacting the CallPeer associated with this MediaHandler. |
protected static int |
getNextMediaPortToTry()
Gets the port that we should try to bind our next media stream's RTP socket to. |
StreamConnector |
getStreamConnector(MediaType mediaType)
Returns the StreamConnector instance that this media handler should use for streams of the specified mediaType. |
protected static void |
initializePortNumbers()
(Re)Sets the minPortNumber and maxPortNumber to their defaults or to the values specified in the ConfigurationService. |
void |
sendHolePunchPacket(MediaStreamTarget target,
MediaType type)
Send empty UDP packet to target destination data/control ports in order to open port on NAT or RTP proxy if any. |
protected static void |
setNextMediaPortToTry(int nextMediaPortToTry)
Sets the port that we should try to bind our next media stream's RTP socket to |
protected void |
setTrafficClass(MediaStreamTarget target,
MediaType type)
Set traffic class (QoS) for the RTP socket. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected TransportManager(U callPeer)
callPeer - the MediaAwareCallPeer whose traffic we will be
taking care of.| Method Detail |
|---|
public StreamConnector getStreamConnector(MediaType mediaType)
throws OperationFailedException
mediaType - the MediaType that we'd like to create a
connector for.
OperationFailedException - in case we failed to initialize our
connector.public void closeStreamConnector(MediaType mediaType)
mediaType - the MediaType associated with the
StreamConnector to close
protected void closeStreamConnector(MediaType mediaType,
StreamConnector streamConnector)
mediaType - the MediaType associated with the specified
streamConnectorstreamConnector - the StreamConnector to be closedcloseStreamConnector(MediaType)
protected StreamConnector createStreamConnector(MediaType mediaType)
throws OperationFailedException
mediaType - the MediaType of the stream for which a new
StreamConnector is to be created
OperationFailedException - if the binding of the sockets fails.protected static void initializePortNumbers()
public InetAddress getLastUsedLocalHost()
public void sendHolePunchPacket(MediaStreamTarget target,
MediaType type)
target - MediaStreamTargettype - the MediaType of the connector we'd like to send
the hole punching packet through.
protected void setTrafficClass(MediaStreamTarget target,
MediaType type)
target - MediaStreamTargettype - the MediaType of the connector we'd like to set
traffic classprotected abstract InetAddress getIntendedDestination(U peer)
peer - the CallPeer that we would contact.
IllegalArgumentException - if destination is not a valid
host/ip/fqdnpublic U getCallPeer()
MediaAwareCallPeer that this transport manager is
serving.
MediaAwareCallPeer that this transport manager is
serving.protected static int getNextMediaPortToTry()
protected static void setNextMediaPortToTry(int nextMediaPortToTry)
nextMediaPortToTry - the port that we should try to bind our next
media stream's RTP socket topublic abstract String getICECandidateExtendedType()
public abstract String getICEState()
public static String getICECandidateExtendedType(org.ice4j.ice.Agent iceAgent)
iceAgent - The ICE agent managing the ICE offer/answer exchange,
collecting and selecting the candidate.
|
Jitsi: the OpenSource Java VoIP and Instant Messaging client. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||