tdlib-obf API
Reference documentation for the public tdlib-obf API, generated from TDLib schemas and public headers
Loading...
Searching...
No Matches
td::td_api::poll Class Referencefinal

#include </home/runner/work/tdlib-obf/tdlib-obf/td/generate/auto/td/telegram/td_api.h>

Inheritance diagram for td::td_api::poll:
td::td_api::Object td::TlObject

Public Member Functions

 poll ()
 
 poll (int64 id_, object_ptr< formattedText > &&question_, array< object_ptr< pollOption > > &&options_, int32 total_voter_count_, array< object_ptr< MessageSender > > &&recent_voter_ids_, bool can_get_voters_, bool is_anonymous_, bool allows_multiple_answers_, bool allows_revoting_, array< int32 > &&option_order_, object_ptr< PollType > &&type_, int32 open_period_, int32 close_date_, bool is_closed_, object_ptr< PollVoteRestrictionReason > &&vote_restriction_reason_)
 
void store (TlStorerToString &s, const char *field_name) const final
 
- Public Member Functions inherited from td::TlObject
virtual void store (TlStorerUnsafe &s) const
 
virtual void store (TlStorerCalcLength &s) const
 
 TlObject ()=default
 
 TlObject (const TlObject &)=delete
 
TlObjectoperator= (const TlObject &)=delete
 
 TlObject (TlObject &&)=default
 
TlObjectoperator= (TlObject &&)=default
 
virtual ~TlObject ()=default
 

Public Attributes

int64 id_
 Unique poll identifier.
 
object_ptr< formattedTextquestion_
 Poll question; 1-300 characters; may contain only custom emoji entities.
 
array< object_ptr< pollOption > > options_
 List of poll answer options.
 
int32 total_voter_count_
 Total number of voters, participating in the poll.
 
array< object_ptr< MessageSender > > recent_voter_ids_
 Identifiers of recent voters, if the poll is non-anonymous and poll results are available.
 
bool can_get_voters_
 True, if the current user can get voters in the poll.
 
bool is_anonymous_
 True, if the poll is anonymous.
 
bool allows_multiple_answers_
 True, if multiple answer options can be chosen simultaneously.
 
bool allows_revoting_
 True, if the poll can be answered multiple times.
 
array< int32option_order_
 The list of 0-based poll identifiers in which the options of the poll must be shown; empty if the order of options must not be changed.
 
object_ptr< PollTypetype_
 Type of the poll.
 
int32 open_period_
 Amount of time the poll will be active after creation, in seconds.
 
int32 close_date_
 Point in time (Unix timestamp) when the poll will automatically be closed.
 
bool is_closed_
 True, if the poll is closed.
 
object_ptr< PollVoteRestrictionReasonvote_restriction_reason_
 Reason why the current user can&#x27;t vote in the poll; may be null if voting is allowed.
 

Static Public Attributes

static const std::int32_t ID = -1432310641
 Identifier uniquely determining a type of the object.
 

Detailed Description

Describes a poll.

Definition at line 52095 of file td_api.h.

Constructor & Destructor Documentation

◆ poll() [1/2]

td::td_api::poll::poll ( )

Describes a poll.

◆ poll() [2/2]

td::td_api::poll::poll ( int64  id_,
object_ptr< formattedText > &&  question_,
array< object_ptr< pollOption > > &&  options_,
int32  total_voter_count_,
array< object_ptr< MessageSender > > &&  recent_voter_ids_,
bool  can_get_voters_,
bool  is_anonymous_,
bool  allows_multiple_answers_,
bool  allows_revoting_,
array< int32 > &&  option_order_,
object_ptr< PollType > &&  type_,
int32  open_period_,
int32  close_date_,
bool  is_closed_,
object_ptr< PollVoteRestrictionReason > &&  vote_restriction_reason_ 
)

Describes a poll.

Parameters
[in]id_Unique poll identifier.
[in]question_Poll question; 1-300 characters; may contain only custom emoji entities.
[in]options_List of poll answer options.
[in]total_voter_count_Total number of voters, participating in the poll.
[in]recent_voter_ids_Identifiers of recent voters, if the poll is non-anonymous and poll results are available.
[in]can_get_voters_True, if the current user can get voters in the poll.
[in]is_anonymous_True, if the poll is anonymous.
[in]allows_multiple_answers_True, if multiple answer options can be chosen simultaneously.
[in]allows_revoting_True, if the poll can be answered multiple times.
[in]option_order_The list of 0-based poll identifiers in which the options of the poll must be shown; empty if the order of options must not be changed.
[in]type_Type of the poll.
[in]open_period_Amount of time the poll will be active after creation, in seconds.
[in]close_date_Point in time (Unix timestamp) when the poll will automatically be closed.
[in]is_closed_True, if the poll is closed.
[in]vote_restriction_reason_Reason why the current user can&#x27;t vote in the poll; may be null if voting is allowed.

Member Function Documentation

◆ store()

void td::td_api::poll::store ( TlStorerToString &  s,
const char *  field_name 
) const
finalvirtual

Helper function for to_string method. Appends string representation of the object to the storer.

Parameters
[in]sStorer to which object string representation will be appended.
[in]field_nameObject field_name if applicable.

Implements td::TlObject.

Member Data Documentation

◆ allows_multiple_answers_

bool td::td_api::poll::allows_multiple_answers_

True, if multiple answer options can be chosen simultaneously.

Definition at line 52120 of file td_api.h.

◆ allows_revoting_

bool td::td_api::poll::allows_revoting_

True, if the poll can be answered multiple times.

Definition at line 52122 of file td_api.h.

◆ can_get_voters_

bool td::td_api::poll::can_get_voters_

True, if the current user can get voters in the poll.

Definition at line 52116 of file td_api.h.

◆ close_date_

int32 td::td_api::poll::close_date_

Point in time (Unix timestamp) when the poll will automatically be closed.

Definition at line 52130 of file td_api.h.

◆ ID

const std::int32_t td::td_api::poll::ID = -1432310641
static

Identifier uniquely determining a type of the object.

Definition at line 52163 of file td_api.h.

◆ id_

int64 td::td_api::poll::id_

Unique poll identifier.

Definition at line 52106 of file td_api.h.

◆ is_anonymous_

bool td::td_api::poll::is_anonymous_

True, if the poll is anonymous.

Definition at line 52118 of file td_api.h.

◆ is_closed_

bool td::td_api::poll::is_closed_

True, if the poll is closed.

Definition at line 52132 of file td_api.h.

◆ open_period_

int32 td::td_api::poll::open_period_

Amount of time the poll will be active after creation, in seconds.

Definition at line 52128 of file td_api.h.

◆ option_order_

array<int32> td::td_api::poll::option_order_

The list of 0-based poll identifiers in which the options of the poll must be shown; empty if the order of options must not be changed.

Definition at line 52124 of file td_api.h.

◆ options_

array<object_ptr<pollOption> > td::td_api::poll::options_

List of poll answer options.

Definition at line 52110 of file td_api.h.

◆ question_

object_ptr<formattedText> td::td_api::poll::question_

Poll question; 1-300 characters; may contain only custom emoji entities.

Definition at line 52108 of file td_api.h.

◆ recent_voter_ids_

array<object_ptr<MessageSender> > td::td_api::poll::recent_voter_ids_

Identifiers of recent voters, if the poll is non-anonymous and poll results are available.

Definition at line 52114 of file td_api.h.

◆ total_voter_count_

int32 td::td_api::poll::total_voter_count_

Total number of voters, participating in the poll.

Definition at line 52112 of file td_api.h.

◆ type_

object_ptr<PollType> td::td_api::poll::type_

Type of the poll.

Definition at line 52126 of file td_api.h.

◆ vote_restriction_reason_

object_ptr<PollVoteRestrictionReason> td::td_api::poll::vote_restriction_reason_

Reason why the current user can&#x27;t vote in the poll; may be null if voting is allowed.

Definition at line 52134 of file td_api.h.


The documentation for this class was generated from the following file: