|
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<CallPeerJabberImpl>
net.java.sip.communicator.impl.protocol.jabber.TransportManagerJabberImpl
public abstract class TransportManagerJabberImpl
TransportManagers gather local candidates for incoming and outgoing calls. Their work starts by calling a start method which, using the remote peer's session description, would start the harvest. Calling a second wrapup method would deliver the candidate harvest, possibly after blocking if it has not yet completed.
| Constructor Summary | |
|---|---|
protected |
TransportManagerJabberImpl(CallPeerJabberImpl callPeer)
Creates a new instance of this transport manager, binding it to the specified peer. |
| Method Summary | |
|---|---|
void |
close()
Releases the resources acquired by this TransportManager and prepares it for garbage collection. |
protected static ContentPacketExtension |
findContentByName(Iterable<ContentPacketExtension> cpExtList,
String name)
Looks through the cpExtList and returns the ContentPacketExtension with the specified name. |
protected int |
getCurrentGeneration()
Returns the generation that our current candidates belong to. |
protected InetAddress |
getIntendedDestination(CallPeerJabberImpl peer)
Returns the InetAddress that is most likely to be to be used as a next hop when contacting the specified destination. |
protected String |
getNextID()
Returns the ID that we will be assigning to the next candidate we create. |
abstract MediaStreamTarget |
getStreamTarget(MediaType mediaType)
Gets the MediaStreamTarget to be used as the target of the MediaStream with a specific MediaType. |
abstract String |
getXmlNamespace()
Gets the XML namespace of the Jingle transport implemented by this TransportManagerJabberImpl. |
protected void |
incrementGeneration()
Increments the generation that we are assigning candidates. |
protected ContentPacketExtension |
removeContent(Iterable<ContentPacketExtension> contents,
String name)
Removes a content with a specific name from a specific collection of contents and closes any associated StreamConnector. |
abstract void |
removeContent(String name)
Removes a content with a specific name from the transport-related part of the session represented by this TransportManagerJabberImpl which may have been reported through previous calls to the startCandidateHarvest and startConnectivityEstablishment methods. |
abstract void |
startCandidateHarvest(List<ContentPacketExtension> theirOffer,
List<ContentPacketExtension> ourAnswer,
TransportInfoSender transportInfoSender)
Starts transport candidate harvest. |
abstract void |
startCandidateHarvest(List<ContentPacketExtension> ourOffer,
TransportInfoSender transportInfoSender)
Starts transport candidate harvest. |
boolean |
startConnectivityEstablishment(Iterable<ContentPacketExtension> remote)
Starts the connectivity establishment of this TransportManagerJabberImpl i.e. |
abstract List<ContentPacketExtension> |
wrapupCandidateHarvest()
Notifies the transport manager that it should conclude candidate harvesting as soon as possible and return the lists of candidates gathered so far. |
void |
wrapupConnectivityEstablishment()
Notifies this TransportManagerJabberImpl that it should conclude any started connectivity establishment. |
| Methods inherited from class net.java.sip.communicator.service.protocol.media.TransportManager |
|---|
closeStreamConnector, closeStreamConnector, createStreamConnector, getCallPeer, getICECandidateExtendedType, getICECandidateExtendedType, getICEState, getLastUsedLocalHost, getNextMediaPortToTry, getStreamConnector, initializePortNumbers, sendHolePunchPacket, setNextMediaPortToTry, setTrafficClass |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected TransportManagerJabberImpl(CallPeerJabberImpl callPeer)
callPeer - the CallPeer whose traffic we will be taking
care of.| Method Detail |
|---|
protected InetAddress getIntendedDestination(CallPeerJabberImpl peer)
getIntendedDestination in class TransportManager<CallPeerJabberImpl>peer - the CallPeer that we would contact.
IllegalArgumentException - if destination is not a valid
host/IP/FQDNprotected String getNextID()
public abstract MediaStreamTarget getStreamTarget(MediaType mediaType)
mediaType - the MediaType of the MediaStream which
is to have its target set to the returned
MediaStreamTarget
public abstract String getXmlNamespace()
protected int getCurrentGeneration()
protected void incrementGeneration()
public abstract void startCandidateHarvest(List<ContentPacketExtension> theirOffer,
List<ContentPacketExtension> ourAnswer,
TransportInfoSender transportInfoSender)
throws OperationFailedException
wrapupCandidateHarvest() method which would be called once we
absolutely need the candidates.
theirOffer - a media description offer that we've received from the
remote party and that we should use in case we need to know what
transports our peer is using.ourAnswer - the content descriptions that we should be adding our
transport lists to (although not necessarily in this very instance).transportInfoSender - the TransportInfoSender to be used by
this TransportManagerJabberImpl to send transport-info
JingleIQs from the local peer to the remote peer if this
TransportManagerJabberImpl wishes to utilize
transport-info. Local candidate addresses sent by this
TransportManagerJabberImpl in transport-info are
expected to not be included in the result of
wrapupCandidateHarvest().
OperationFailedException - if we fail to allocate a port number.
public abstract void startCandidateHarvest(List<ContentPacketExtension> ourOffer,
TransportInfoSender transportInfoSender)
throws OperationFailedException
wrapupCandidateHarvest() method which would be called once we
absolutely need the candidates.
ourOffer - the content descriptions that we should be adding our
transport lists to (although not necessarily in this very instance).transportInfoSender - the TransportInfoSender to be used by
this TransportManagerJabberImpl to send transport-info
JingleIQs from the local peer to the remote peer if this
TransportManagerJabberImpl wishes to utilize
transport-info. Local candidate addresses sent by this
TransportManagerJabberImpl in transport-info are
expected to not be included in the result of
wrapupCandidateHarvest().
OperationFailedException - if we fail to allocate a port number.public abstract List<ContentPacketExtension> wrapupCandidateHarvest()
protected static ContentPacketExtension findContentByName(Iterable<ContentPacketExtension> cpExtList,
String name)
ContentPacketExtension with the specified name.
cpExtList - the list that we will be searching for a specific
content.name - the name of the content element we are looking for.
ContentPacketExtension with the specified name or
null if no such content element exists.public boolean startConnectivityEstablishment(Iterable<ContentPacketExtension> remote)
remote - the collection of ContentPacketExtensions which
represents the remote counterpart of the negotiation between the local
and the remote peer
public void wrapupConnectivityEstablishment()
throws OperationFailedException
OperationFailedException - if anything goes wrong with connectivity
establishment (i.e. ICE failed, ...)public abstract void removeContent(String name)
Note: Because TransportManager deals with
MediaTypes, not content names and
TransportManagerJabberImpl does not implement translating from
content name to MediaType, implementers are expected to call
TransportManager.closeStreamConnector(MediaType).
name - the name of the content to be removed from the
transport-related part of the session represented by this
TransportManagerJabberImpl
protected ContentPacketExtension removeContent(Iterable<ContentPacketExtension> contents,
String name)
contents - the collection of contents to remove the content with the
specified name fromname - the name of the content to remove
public void close()
|
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 | |||||||||