Preparing search index...
The search index is not available
Documentation - v0.19.5
Documentation
@mtcute/node
utils
CurrentUserService
Class CurrentUserService
Hierarchy (
View Summary
)
BaseService
CurrentUserService
Index
Constructors
constructor
Properties
_driver
_log
_reader
Map
_writer
Map
Methods
_deserialize
Tl
_serialize
Tl
fetch
get
Cached
store
store
From
update
Constructors
constructor
new
CurrentUserService
(
_kv
:
IKeyValueRepository
,
opts
:
ServiceOptions
,
)
:
CurrentUserService
Parameters
_kv
:
IKeyValueRepository
opts
:
ServiceOptions
Returns
CurrentUserService
Properties
Protected
_driver
_driver
:
IStorageDriver
Protected
_log
_log
:
Logger
Protected
_reader
Map
_readerMap
:
TlReaderMap
Protected
_writer
Map
_writerMap
:
TlWriterMap
Methods
Protected
_deserialize
Tl
_deserializeTl
(
data
:
Uint8Array
)
:
null
|
TlObject
Parameters
data
:
Uint8Array
Returns
null
|
TlObject
Protected
_serialize
Tl
_serializeTl
(
obj
:
TlObject
)
:
Uint8Array
Parameters
obj
:
TlObject
Returns
Uint8Array
fetch
fetch
()
:
Promise
<
null
|
CurrentUserInfo
>
Returns
Promise
<
null
|
CurrentUserInfo
>
get
Cached
getCached
(
safe
?:
boolean
)
:
null
|
CurrentUserInfo
Parameters
safe
:
boolean
= false
Returns
null
|
CurrentUserInfo
store
store
(
info
:
null
|
CurrentUserInfo
)
:
Promise
<
void
>
Parameters
info
:
null
|
CurrentUserInfo
Returns
Promise
<
void
>
store
From
storeFrom
(
user
:
TypeUser
)
:
Promise
<
CurrentUserInfo
>
Parameters
user
:
TypeUser
Returns
Promise
<
CurrentUserInfo
>
update
update
(
params
:
{
isPremium
?:
boolean
;
username
?:
string
;
usernames
?:
string
[]
}
,
)
:
Promise
<
void
>
Parameters
params
:
{
isPremium
?:
boolean
;
username
?:
string
;
usernames
?:
string
[]
}
Returns
Promise
<
void
>
Settings
Member Visibility
Protected
Inherited
Theme
OS
Light
Dark
On This Page
Constructors
constructor
Properties
_driver
_log
_reader
Map
_writer
Map
Methods
_deserialize
Tl
_serialize
Tl
fetch
get
Cached
store
store
From
update
Documentation - v0.19.5
Loading...