-
- All Implemented Interfaces:
public class ChannelNumberAttribute extends Attribute
The CHANNEL-NUMBER attribute is used to known on which channel the TURN client want to send data.
-
-
Field Summary
Fields Modifier and Type Field Description public final static StringNAMEpublic final static charDATA_LENGTHprivate charchannelNumber
-
Method Summary
Modifier and Type Method Description chargetChannelNumber()Get the channel number. voidsetChannelNumber(char channelNumber)Set the channel number. booleanequals(Object obj)Compares two STUN Attributes. StringgetName()Returns the human readable name of this attribute. chargetDataLength()Returns the length of this attribute's body. Array<byte>encode()Returns a binary representation of this attribute. static booleanisValidRange(char channelNo)Determines if the channelNo is in valid range. -
-
Method Detail
-
getChannelNumber
char getChannelNumber()
Get the channel number.
-
setChannelNumber
void setChannelNumber(char channelNumber)
Set the channel number.
- Parameters:
channelNumber- channel number
-
equals
boolean equals(Object obj)
Compares two STUN Attributes. Attributes are considered equal when their type, length, and all data are the same.
- Parameters:
obj- the object to compare this attribute with.
-
getName
String getName()
Returns the human readable name of this attribute. Attribute names do not really matter from the protocol point of view. They are only used for debugging and readability.
-
getDataLength
char getDataLength()
Returns the length of this attribute's body.
-
isValidRange
static boolean isValidRange(char channelNo)
Determines if the channelNo is in valid range.
- Parameters:
channelNo- the channelNo to validate.
-
-
-
-