public class RtcpHandler extends Object implements PacketHandler
Constructor and Description |
---|
RtcpHandler(Scheduler scheduler,
RtpStatistics statistics) |
Modifier and Type | Method and Description |
---|---|
boolean |
canHandle(byte[] packet) |
boolean |
canHandle(byte[] packet,
int dataLength,
int offset) |
int |
compareTo(PacketHandler o) |
void |
disableSRTCP()
Disables secure layer on the channel, meaning all traffic is treated as plain RTCP.
|
void |
enableSRTCP(DtlsHandler dtlsHandler)
Secures the channel, meaning all traffic is SRTCP.
|
long |
getNextScheduledReport()
Gets the time interval until the next report is sent.
|
int |
getPipelinePriority() |
byte[] |
handle(byte[] packet,
InetSocketAddress localPeer,
InetSocketAddress remotePeer) |
byte[] |
handle(byte[] packet,
int dataLength,
int offset,
InetSocketAddress localPeer,
InetSocketAddress remotePeer) |
boolean |
isInitial()
Gets whether the handler is in initial stage.
The handler is in initial stage until it has sent at least one RTCP packet during the current RTP session. |
boolean |
isJoined()
Gets whether the handler is currently joined to an RTP Session.
|
void |
joinRtpSession()
Upon joining the session, the participant initializes tp to 0, tc to 0, senders to 0, pmembers to 1, members to 1,
we_sent to false, rtcp_bw to the specified fraction of the session bandwidth, initial to true, and avg_rtcp_size to the
probable size of the first RTCP packet that the application will later construct.
|
void |
leaveRtpSession() |
void |
reset() |
void |
setChannel(DatagramChannel channel) |
void |
setPipelinePriority(int pipelinePriority) |
public RtcpHandler(Scheduler scheduler, RtpStatistics statistics)
public int getPipelinePriority()
getPipelinePriority
in interface PacketHandler
public void setPipelinePriority(int pipelinePriority)
public void setChannel(DatagramChannel channel)
public boolean isInitial()
public boolean isJoined()
public void joinRtpSession()
public void leaveRtpSession()
public long getNextScheduledReport()
public void enableSRTCP(DtlsHandler dtlsHandler)
remotePeerFingerprint
- The DTLS fingerprint of the remote peer. Use to setup DTLS keying material.public void disableSRTCP()
public boolean canHandle(byte[] packet)
canHandle
in interface PacketHandler
public boolean canHandle(byte[] packet, int dataLength, int offset)
canHandle
in interface PacketHandler
public byte[] handle(byte[] packet, InetSocketAddress localPeer, InetSocketAddress remotePeer) throws PacketHandlerException
handle
in interface PacketHandler
PacketHandlerException
public byte[] handle(byte[] packet, int dataLength, int offset, InetSocketAddress localPeer, InetSocketAddress remotePeer) throws PacketHandlerException
handle
in interface PacketHandler
PacketHandlerException
public void reset()
public int compareTo(PacketHandler o)
compareTo
in interface Comparable<PacketHandler>
Copyright © 2016 TeleStax, Inc.. All Rights Reserved.