Class ChatAdministratorRights
java.lang.Object
io.micronaut.chatbots.telegram.api.ChatAdministratorRights
Represents the rights of an administrator in a chat.
ChatAdministratorRights
- Since:
- 1.0.0
- Author:
- Sergio del Amo
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescription@NonNull Boolean
@NonNull Boolean
@Nullable Boolean
@NonNull Boolean
@NonNull Boolean
@NonNull Boolean
@Nullable Boolean
@Nullable Boolean
@NonNull Boolean
@NonNull Boolean
@NonNull Boolean
void
setAnonymous
(@NonNull Boolean anonymous) void
setCanChangeInfo
(@NonNull Boolean canChangeInfo) void
setCanDeleteMessages
(@NonNull Boolean canDeleteMessages) void
setCanEditMessages
(@Nullable Boolean canEditMessages) void
setCanInviteUsers
(@NonNull Boolean canInviteUsers) void
setCanManageChat
(@NonNull Boolean canManageChat) void
setCanManageVideoChats
(@NonNull Boolean canManageVideoChats) void
setCanPinMessages
(@Nullable Boolean canPinMessages) void
setCanPostMessages
(@Nullable Boolean canPostMessages) void
setCanPromoteMembers
(@NonNull Boolean canPromoteMembers) void
setCanRestrictMembers
(@NonNull Boolean canRestrictMembers)
-
Constructor Details
-
ChatAdministratorRights
public ChatAdministratorRights()
-
-
Method Details
-
isAnonymous
- Returns:
- True, if the user's presence in the chat is hidden
-
setAnonymous
- Parameters:
anonymous
- True, if the user's presence in the chat is hidden
-
getCanManageChat
- Returns:
- True, if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege
-
setCanManageChat
- Parameters:
canManageChat
- True, if the administrator can access the chat event log, chat statistics, message statistics in channels, see channel members, see anonymous administrators in supergroups and ignore slow mode. Implied by any other administrator privilege
-
getCanDeleteMessages
- Returns:
- True, if the administrator can delete messages of other users
-
setCanDeleteMessages
- Parameters:
canDeleteMessages
- True, if the administrator can delete messages of other users
-
getCanManageVideoChats
- Returns:
- True, if the administrator can manage video chats
-
setCanManageVideoChats
- Parameters:
canManageVideoChats
- True, if the administrator can manage video chats
-
getCanRestrictMembers
- Returns:
- True, if the administrator can restrict, ban or unban chat members
-
setCanRestrictMembers
- Parameters:
canRestrictMembers
- True, if the administrator can restrict, ban or unban chat members
-
getCanPromoteMembers
- Returns:
- True, if the administrator can add new administrators with a subset of their own privileges or demote administrators that he has promoted, directly or indirectly (promoted by administrators that were appointed by the user)
-
setCanPromoteMembers
- Parameters:
canPromoteMembers
- True, if the administrator can add new administrators with a subset of their own privileges or demote administrators that he has promoted, directly or indirectly (promoted by administrators that were appointed by the user)
-
getCanChangeInfo
- Returns:
- True, if the user is allowed to change the chat title, photo and other settings
-
setCanChangeInfo
- Parameters:
canChangeInfo
- True, if the user is allowed to change the chat title, photo and other settings
-
getCanInviteUsers
- Returns:
- True, if the user is allowed to invite new users to the chat
-
setCanInviteUsers
- Parameters:
canInviteUsers
- True, if the user is allowed to invite new users to the chat
-
getCanPostMessages
- Returns:
- Optional. True, if the administrator can post in the channel; channels only
-
setCanPostMessages
- Parameters:
canPostMessages
- Optional. True, if the administrator can post in the channel; channels only
-
getCanEditMessages
- Returns:
- Optional. True, if the administrator can edit messages of other users and can pin messages; channels only
-
setCanEditMessages
- Parameters:
canEditMessages
- True, if the administrator can edit messages of other users and can pin messages; channels only
-
getCanPinMessages
- Returns:
- Optional. True, if the user is allowed to pin messages; groups and supergroups only
-
setCanPinMessages
- Parameters:
canPinMessages
- Optional. True, if the user is allowed to pin messages; groups and supergroups only
-