localAddr = new SessionAddress(sessAddr.getDataAddress(), localPort); rtpMgrs[i].initialize(localAddr);
/** * Sets the direction of the <tt>MediaStream</tt> of this <tt>Channel</tt>. * <p> * <b>Warning</b>: The method does nothing if latching has not finished. * </p> * * @param direction the <tt>MediaDirection</tt> to set on the * <tt>MediaStream</tt> of this <tt>Channel</tt> */ public void setDirection(MediaDirection direction) { // XXX We modify the stream direction only after latching has finished. if (streamTarget.getDataAddress() != null) { stream.setDirection(direction); } touch(); // It seems this Channel is still active. }
streamTarget.setControlPort(p.getPort()); InetAddress dataAddr = streamTarget.getDataAddress(); int dataPort = streamTarget.getDataPort();
/** * Removes a target from our session. If a target is removed, there will be * no data sent to that address. * * @param target Destination target to be removed */ public void removeTarget(SessionAddress target) { if (controlOutputStream != null) controlOutputStream .removeTarget( target.getControlAddress(), target.getControlPort()); if (dataOutputStream != null) dataOutputStream .removeTarget( target.getDataAddress(), target.getDataPort()); }
localAddr = new SessionAddress(sessAddr.getDataAddress(), localPort); rtpMgrs[i].initialize(localAddr);
/** * Add a stream target. A stream target is the destination address which * this RTP session will send its data to. For a single session, we can add * multiple SessionAddresses, and for each address, one copy of data will be * sent to. * * @param target Destination target address * @throws IOException if there was a socket-related error while adding the * specified target */ public void addTarget(SessionAddress target) throws IOException { InetAddress controlAddress = target.getControlAddress(); if (controlAddress != null) { getControlOutputStream().addTarget( controlAddress, target.getControlPort()); } getDataOutputStream().addTarget( target.getDataAddress(), target.getDataPort()); }
localAddr = new SessionAddress(sessAddr.getDataAddress(), localPort); rtpMgrs[i].initialize(localAddr);