dao

package
v0.90.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 12, 2022 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Dao

type Dao struct {
	authsession_client.AuthsessionClient
	status_client.StatusClient
	*bff_proxy_client.BFFProxyClient
	// contains filtered or unexported fields
}

func New

func New(c config.Config) *Dao

func (*Dao) GetCacheApiLayer

func (d *Dao) GetCacheApiLayer(ctx context.Context, authKeyId int64) (int32, bool)

func (*Dao) GetCacheClient

func (d *Dao) GetCacheClient(ctx context.Context, authKeyId int64) string

func (*Dao) GetCacheLangpack

func (d *Dao) GetCacheLangpack(ctx context.Context, authKeyId int64) string

func (*Dao) GetCachePermAuthKeyId added in v0.87.2

func (d *Dao) GetCachePermAuthKeyId(ctx context.Context, authKeyId int64) int64

func (*Dao) GetCachePushSessionID

func (d *Dao) GetCachePushSessionID(ctx context.Context, userId int64, authKeyId int64) (int64, bool)

func (*Dao) GetCacheUserID

func (d *Dao) GetCacheUserID(ctx context.Context, authKeyId int64) (int64, bool)

func (*Dao) GetFutureSalts

func (d *Dao) GetFutureSalts(ctx context.Context, authKeyId int64, num int32) ([]*mtproto.TLFutureSalt, error)

func (*Dao) GetKeyStateData

func (d *Dao) GetKeyStateData(ctx context.Context, authKeyId int64) (*authsession.AuthKeyStateData, error)

func (*Dao) GetOrFetchNewSalt

func (d *Dao) GetOrFetchNewSalt(ctx context.Context, authKeyId int64) (salt, lastInvalidSalt *mtproto.TLFutureSalt, err error)

func (*Dao) Invoke

func (d *Dao) Invoke(rpcMetaData *metadata.RpcMetadata, object mtproto.TLObject) (mtproto.TLObject, error)

func (*Dao) PutCacheApiLayer

func (d *Dao) PutCacheApiLayer(ctx context.Context, authKeyId int64, layer int32)

func (*Dao) PutCacheClient

func (d *Dao) PutCacheClient(ctx context.Context, authKeyId int64, v string)

func (*Dao) PutCacheLangpack

func (d *Dao) PutCacheLangpack(ctx context.Context, authKeyId int64, v string)

func (*Dao) PutCachePermAuthKeyId added in v0.87.2

func (d *Dao) PutCachePermAuthKeyId(ctx context.Context, authKeyId, kId int64)

func (*Dao) PutCachePushSessionId

func (d *Dao) PutCachePushSessionId(ctx context.Context, authKeyId, sessionId int64)

func (*Dao) PutCacheUserId

func (d *Dao) PutCacheUserId(ctx context.Context, authKeyId int64, userId int64)

func (*Dao) PutUploadInitConnection

func (d *Dao) PutUploadInitConnection(ctx context.Context, authKeyId int64, layer int32, ip string, initConnection *mtproto.TLInitConnection) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL