ChatMember class
This object contains information about one member of a chat. Currently, the following 6 types of chat members are supported: ChatMemberOwner, ChatMemberAdministrator, ChatMemberMember, ChatMemberRestricted, ChatMemberLeft, ChatMemberBanned
Constructors
- ChatMember({required User user, required String status, String? customTitle, int? untilDate, bool? canBeEdited, bool? canPostMessages, bool? canEditMessages, bool? canDeleteMessages, bool? canRestrictMembers, bool? canPromoteMembers, bool? canChangeInfo, bool? canInviteUsers, bool? canPinMessages, bool? isMember, bool? canSendMessages, bool? canSendMediaMessages, bool? canSendPolls, bool? canSendOtherMessages, bool? canAddWebPagePreviews, bool? canManageVideoChats, bool? canManageChat, bool? isAnonymous})
- Basic constructor
Properties
- canAddWebPagePreviews ↔ bool?
-
True, if the user is allowed to add web page previews to their messages
getter/setter pair
- canBeEdited ↔ bool?
-
True, if the bot is allowed to edit administrator privileges of that user
getter/setter pair
- canChangeInfo ↔ bool?
-
True, if the user is allowed to change the chat title, photo and other
settings
getter/setter pair
- canDeleteMessages ↔ bool?
-
True, if the administrator can delete messages of other users
getter/setter pair
- canEditMessages ↔ bool?
-
True, if the administrator can edit messages of other users and can pin
messages; channels only
getter/setter pair
- canInviteUsers ↔ bool?
-
True, if the user is allowed to invite new users to the chat
getter/setter pair
- canManageChat ↔ bool?
-
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
getter/setter pair
- canManageVideoChats ↔ bool?
-
True, if the administrator can manage video chats
getter/setter pair
- canPinMessages ↔ bool?
-
True, if the user is allowed to pin messages; groups and supergroups only
getter/setter pair
- canPostMessages ↔ bool?
-
True, if the administrator can post in the channel; channels only
getter/setter pair
- canPromoteMembers ↔ bool?
-
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)
getter/setter pair
- canRestrictMembers ↔ bool?
-
True, if the administrator can restrict, ban or unban chat members
getter/setter pair
- canSendMediaMessages ↔ bool?
-
True, if the user is allowed to send audios, documents, photos, videos,
video notes and voice notes
getter/setter pair
- canSendMessages ↔ bool?
-
True, if the user is allowed to send text messages, contacts,
locations and venues
getter/setter pair
- canSendOtherMessages ↔ bool?
-
True, if the user is allowed to send animations, games, stickers and
use inline bots
getter/setter pair
- canSendPolls ↔ bool?
-
True, if the user is allowed to send polls
getter/setter pair
- customTitle ↔ String?
-
Custom title for this user
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- isAnonymous ↔ bool?
-
True, if the user's presence in the chat is hidden
getter/setter pair
- isMember ↔ bool?
-
True, if the user is a member of the chat at the moment of the request
getter/setter pair
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- status ↔ String
-
The member's status in the chat
getter/setter pair
- untilDate ↔ int?
-
Date when restrictions will be lifted for this user; unix time.
If 0, then the user is restricted forever
getter/setter pair
- user ↔ User
-
Information about the user
getter/setter pair
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map - Creates a json from the object
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
fromJson(
Map< String, dynamic> json) → ChatMember - Creates a object from a json
-
listFromJsonArray(
List array) → List< ChatMember> - Creates a list of object from a json array