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::inputMessagePoll Class Referencefinal

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

Inheritance diagram for td::td_api::inputMessagePoll:
td::td_api::InputMessageContent td::td_api::Object td::TlObject

Public Member Functions

 inputMessagePoll ()
 
 inputMessagePoll (object_ptr< formattedText > &&question_, array< object_ptr< inputPollOption > > &&options_, object_ptr< formattedText > &&description_, bool is_anonymous_, bool allows_multiple_answers_, bool allows_revoting_, bool shuffle_options_, bool hide_results_until_closes_, object_ptr< InputPollType > &&type_, int32 open_period_, int32 close_date_, bool is_closed_)
 
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

object_ptr< formattedTextquestion_
 Poll question; 1-255 characters (up to 300 characters for bots). Only custom emoji entities are allowed to be added and only by Premium users.
 
array< object_ptr< inputPollOption > > options_
 List of poll answer options; 2-getOption("poll_answer_count_max") options.
 
object_ptr< formattedTextdescription_
 Poll description; pass null to use an empty description; 0-getOption("message_caption_length_max") characters.
 
bool is_anonymous_
 True, if the poll voters are anonymous. Non-anonymous polls can&#x27;t be sent or forwarded to channels.
 
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.
 
bool shuffle_options_
 True, if poll options must be shown in a fixed random order.
 
bool hide_results_until_closes_
 True, if the poll results will appear only after the poll closes.
 
object_ptr< InputPollTypetype_
 Type of the poll.
 
int32 open_period_
 Amount of time the poll will be active after creation, in seconds; 0-getOption("poll_open_period_max"); pass 0 if not specified.
 
int32 close_date_
 Point in time (Unix timestamp) when the poll will automatically be closed; must be 0-getOption("poll_open_period_max") seconds in the future; pass 0 if not specified.
 
bool is_closed_
 True, if the poll needs to be sent already closed; for bots only.
 

Static Public Attributes

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

Detailed Description

A message with a poll. Polls can&#x27;t be sent to secret chats and channel direct messages chats. Polls can be sent to a private chat only if the chat is a chat with a bot or the Saved Messages chat.

Definition at line 29820 of file td_api.h.

Constructor & Destructor Documentation

◆ inputMessagePoll() [1/2]

td::td_api::inputMessagePoll::inputMessagePoll ( )

A message with a poll. Polls can&#x27;t be sent to secret chats and channel direct messages chats. Polls can be sent to a private chat only if the chat is a chat with a bot or the Saved Messages chat.

◆ inputMessagePoll() [2/2]

td::td_api::inputMessagePoll::inputMessagePoll ( object_ptr< formattedText > &&  question_,
array< object_ptr< inputPollOption > > &&  options_,
object_ptr< formattedText > &&  description_,
bool  is_anonymous_,
bool  allows_multiple_answers_,
bool  allows_revoting_,
bool  shuffle_options_,
bool  hide_results_until_closes_,
object_ptr< InputPollType > &&  type_,
int32  open_period_,
int32  close_date_,
bool  is_closed_ 
)

A message with a poll. Polls can&#x27;t be sent to secret chats and channel direct messages chats. Polls can be sent to a private chat only if the chat is a chat with a bot or the Saved Messages chat.

Parameters
[in]question_Poll question; 1-255 characters (up to 300 characters for bots). Only custom emoji entities are allowed to be added and only by Premium users.
[in]options_List of poll answer options; 2-getOption("poll_answer_count_max") options.
[in]description_Poll description; pass null to use an empty description; 0-getOption("message_caption_length_max") characters.
[in]is_anonymous_True, if the poll voters are anonymous. Non-anonymous polls can&#x27;t be sent or forwarded to channels.
[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]shuffle_options_True, if poll options must be shown in a fixed random order.
[in]hide_results_until_closes_True, if the poll results will appear only after the poll closes.
[in]type_Type of the poll.
[in]open_period_Amount of time the poll will be active after creation, in seconds; 0-getOption("poll_open_period_max"); pass 0 if not specified.
[in]close_date_Point in time (Unix timestamp) when the poll will automatically be closed; must be 0-getOption("poll_open_period_max") seconds in the future; pass 0 if not specified.
[in]is_closed_True, if the poll needs to be sent already closed; for bots only.

Member Function Documentation

◆ store()

void td::td_api::inputMessagePoll::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::inputMessagePoll::allows_multiple_answers_

True, if multiple answer options can be chosen simultaneously.

Definition at line 29839 of file td_api.h.

◆ allows_revoting_

bool td::td_api::inputMessagePoll::allows_revoting_

True, if the poll can be answered multiple times.

Definition at line 29841 of file td_api.h.

◆ close_date_

int32 td::td_api::inputMessagePoll::close_date_

Point in time (Unix timestamp) when the poll will automatically be closed; must be 0-getOption("poll_open_period_max") seconds in the future; pass 0 if not specified.

Definition at line 29851 of file td_api.h.

◆ description_

object_ptr<formattedText> td::td_api::inputMessagePoll::description_

Poll description; pass null to use an empty description; 0-getOption("message_caption_length_max") characters.

Definition at line 29835 of file td_api.h.

◆ hide_results_until_closes_

bool td::td_api::inputMessagePoll::hide_results_until_closes_

True, if the poll results will appear only after the poll closes.

Definition at line 29845 of file td_api.h.

◆ ID

const std::int32_t td::td_api::inputMessagePoll::ID = 1305333511
static

Identifier uniquely determining a type of the object.

Definition at line 29879 of file td_api.h.

◆ is_anonymous_

bool td::td_api::inputMessagePoll::is_anonymous_

True, if the poll voters are anonymous. Non-anonymous polls can&#x27;t be sent or forwarded to channels.

Definition at line 29837 of file td_api.h.

◆ is_closed_

bool td::td_api::inputMessagePoll::is_closed_

True, if the poll needs to be sent already closed; for bots only.

Definition at line 29853 of file td_api.h.

◆ open_period_

int32 td::td_api::inputMessagePoll::open_period_

Amount of time the poll will be active after creation, in seconds; 0-getOption("poll_open_period_max"); pass 0 if not specified.

Definition at line 29849 of file td_api.h.

◆ options_

array<object_ptr<inputPollOption> > td::td_api::inputMessagePoll::options_

List of poll answer options; 2-getOption("poll_answer_count_max") options.

Definition at line 29833 of file td_api.h.

◆ question_

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

Poll question; 1-255 characters (up to 300 characters for bots). Only custom emoji entities are allowed to be added and only by Premium users.

Definition at line 29831 of file td_api.h.

◆ shuffle_options_

bool td::td_api::inputMessagePoll::shuffle_options_

True, if poll options must be shown in a fixed random order.

Definition at line 29843 of file td_api.h.

◆ type_

object_ptr<InputPollType> td::td_api::inputMessagePoll::type_

Type of the poll.

Definition at line 29847 of file td_api.h.


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