This class is used to represent a chat id. It is a superclass of ChatID, ChannelID and SupergroupID.
When you want to send a message to a chat, you need to specify the chat id. You can use this class to represent the chat id.
Constructors
-
ID(dynamic id)
-
Creates a new ID object with the passed
id.
const
-
ID.create(dynamic value)
-
Creates a new ID object with the passed
value.
factory
-
ID.fromJson(Map<String, dynamic> json)
-
Creates the ID object from JSON map.
factory
Properties
-
hashCode
→ int
-
Returns the hash code of the id.
no setteroverride
-
id
→ dynamic
-
The id of the chat. It can be an integer or a string.
final
-
runtimeType
→ Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(Invocation invocation)
→ dynamic
-
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson()
→ dynamic
-
Returns the id as a string or an integer.
-
toString()
→ String
-
A string representation of this object.
inherited
Operators
-
operator ==(Object other)
→ bool
-
Equality operator. Returns
true if the passed other is an ID and the id of the other is equal to the id of this ID.
override