public class RTCPHeaderUtils
extends java.lang.Object
Constructor and Description |
---|
RTCPHeaderUtils() |
Modifier and Type | Method and Description |
---|---|
static int |
getLength(byte[] buf,
int off,
int len)
Gets the RTCP packet length in bytes.
|
static int |
getLength(ByteArrayBuffer baf)
Gets the RTCP packet length in bytes.
|
static int |
getPacketType(byte[] buf,
int off,
int len)
Gets the RTCP packet type.
|
static int |
getPacketType(ByteArrayBuffer baf)
Gets the RTCP packet type.
|
static int |
getReportCount(ByteArrayBuffer baf)
Gets the report count field of the RTCP packet specified in the
ByteArrayBuffer that is passed in as a parameter. |
static int |
getVersion(byte[] buf,
int off,
int len)
Gets the RTCP packet version.
|
static boolean |
isValid(byte[] buf,
int off,
int len)
Checks whether the RTCP header is valid or not.
|
static int |
setSenderSSRC(ByteArrayBuffer baf,
int senderSSRC)
Sets the RTCP sender SSRC.
|
public static int getPacketType(byte[] buf, int off, int len)
buf
- the byte buffer that contains the RTCP header.off
- the offset in the byte buffer where the RTCP header starts.len
- the number of bytes in buffer which constitute the actual
data.public static int getPacketType(ByteArrayBuffer baf)
baf
- the ByteArrayBuffer
that contains the RTCP header.public static int getLength(byte[] buf, int off, int len)
buf
- the byte buffer that contains the RTCP header.off
- the offset in the byte buffer where the RTCP header starts.len
- the number of bytes in buffer which constitute the actual
data.public static int getVersion(byte[] buf, int off, int len)
buf
- the byte buffer that contains the RTCP header.off
- the offset in the byte buffer where the RTCP header starts.len
- the number of bytes in buffer which constitute the actual
data.public static boolean isValid(byte[] buf, int off, int len)
buf
- the byte buffer that contains the RTCP header.off
- the offset in the byte buffer where the RTCP header starts.len
- the number of bytes in buffer which constitute the actual
data.public static int setSenderSSRC(ByteArrayBuffer baf, int senderSSRC)
baf
- the ByteArrayBuffer
that contains the RTCP header.senderSSRC
- the sender SSRC to set.public static int getReportCount(ByteArrayBuffer baf)
ByteArrayBuffer
that is passed in as a parameter.baf
- the ByteArrayBuffer
that contains the RTCP header.ByteArrayBuffer
that is passed in as a parameter, or -1 in case
of an error.public static int getLength(ByteArrayBuffer baf)
baf
- the ByteArrayBuffer
that contains the RTCP header.
Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under Apache license.