PollOption class
Class representing a poll option. A poll options can be created by Poll.create and GroupChannelPoll.addPollOption. text is the only field set by the client. Other fields can be set by the server and voting.
A latest poll option instance can be fetched using Poll.get and a poll option can be updated using GroupChannelPoll.updatePoll.
- Annotations
-
- @JsonSerializable()
Constructors
Properties
- createdAt → int
-
Unix timestamp at which the poll option is created.
final
- createdBy ↔ String?
-
UserId of the poll option creator.
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setteroverride
- id → int
-
A unique identifier for this poll option.
final
- pollId → int
-
A unique identifier for the poll which contains this poll option.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- text → String
-
Representing text of this poll option.
final
- updatedAt ↔ int
-
Unix timestamp at which the poll option is updated (ms).
getter/setter pair
- voteCount ↔ int
-
Voter count of this poll option.
getter/setter pair
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Static Methods
-
get(
PollOptionRetrievalParams params, {Chat? chat}) → Future< PollOption> - Fetches latest PollOption representation from the server.