Documentation
Real-time Messaging
API Reference
Agora RTM Java API Reference for Android
Agora RTM Java API Reference for Android
◆ RtmChannelAttribute() [1/2]
io.agora.rtm.RtmChannelAttribute.RtmChannelAttribute |
( |
String |
key, |
|
|
String |
value |
|
) |
| |
Construction method of the RtmChannelAttribute class.
- Parameters
-
key | Key of channel attribute. Must be visible characters and not exceed 32 Bytes. |
value | Value of the channel attribute. Must not exceed 8 KB. |
◆ RtmChannelAttribute() [2/2]
io.agora.rtm.RtmChannelAttribute.RtmChannelAttribute |
( |
String |
key, |
|
|
String |
value, |
|
|
String |
userId, |
|
|
long |
updateTs |
|
) |
| |
Construction method of the RtmChannelAttribute class.
- Parameters
-
key | The attribute name. Must be visible characters and not exceed 32 Bytes in length. |
value | The attribute value. Must not exceed 8 KB in length. |
userId | User ID of the user who makes the latest update to the channel attribute. |
updateTs | The timestamp (ms) of when the channel attribute was last updated. |
◆ setKey()
void io.agora.rtm.RtmChannelAttribute.setKey |
( |
String |
key | ) |
|
Sets the key of the channel attribute.
- Parameters
-
key | Key of channel attribute. Must be visible characters and not exceed 32 Bytes. |
◆ getKey()
String io.agora.rtm.RtmChannelAttribute.getKey |
( |
| ) |
|
Gets the key of the channel attribute.
- Returns
- Key of the channel attribute that is set using the setKey method.
◆ setValue()
void io.agora.rtm.RtmChannelAttribute.setValue |
( |
String |
value | ) |
|
Sets the value of the channel attribute.
- Parameters
-
value | Value of the channel attribute. Must not exceed 8 KB in length. |
◆ getValue()
String io.agora.rtm.RtmChannelAttribute.getValue |
( |
| ) |
|
Gets the value of the channel attribute.
- Returns
- Value of the channel attribute that is set using the setValue method.
◆ getLastUpdateUserId()
String io.agora.rtm.RtmChannelAttribute.getLastUpdateUserId |
( |
| ) |
|
Gets the User ID of the user who makes the latest update to the channel attribute.
- Returns
- User ID of the user who makes the latest update to the channel attribute.
◆ getLastUpdateTs()
long io.agora.rtm.RtmChannelAttribute.getLastUpdateTs |
( |
| ) |
|
Gets the timestamp of when the channel attribute was last updated.
- Returns
- Timestamp of when the channel attribute was last updated in milliseconds.