List of all members | Classes | Public Class Methods | Public Instance Methods
ClientActor Class Reference

Inherits Actor.


This is a low-level Actor interface for interaction with TDLib. The interface is a lot more flexible than the Client interface, however, for most usages the Client interface should be sufficient.


struct  Options
 Options for ClientActor creation. More...

Public Class Methods

static td_api::object_ptr< td_api::Objectexecute (td_api::object_ptr< td_api::Function > request)

Public Instance Methods

 ClientActor (unique_ptr< TdCallback > callback, Options options={})
void request (uint64 id, td_api::object_ptr< td_api::Function > request)
 ~ClientActor ()
 ClientActor (ClientActor &&other)
ClientActoroperator= (ClientActor &&other)
 ClientActor (const ClientActor &other)=delete
ClientActoroperator= (const ClientActor &other)=delete

Constructor & Destructor Documentation

◆ ClientActor() [1/2]

ClientActor ( unique_ptr< TdCallback callback,
Options  options = {} 

Creates a ClientActor using the specified callback.

[in]callbackCallback for outgoing notifications from TDLib.
[in]optionsOptions to create the TDLib.

◆ ~ClientActor()

Destroys the ClientActor and the TDLib instance.

◆ ClientActor() [2/2]

ClientActor ( ClientActor &&  other)

Move constructor.

Method Documentation

◆ request()

void request ( uint64  id,
td_api::object_ptr< td_api::Function request 

Sends one request to TDLib. The answer will be received via callback.

[in]idRequest identifier, must be positive.
[in]requestThe request.

◆ execute()

static td_api::object_ptr<td_api::Object> execute ( td_api::object_ptr< td_api::Function request)

Synchronously executes a TDLib request. Only a few requests can be executed synchronously. May be called from any thread.

[in]requestRequest to the TDLib instance.
The request response.

◆ operator=()

ClientActor& operator= ( ClientActor &&  other)

Move assignment operator.

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