Preparing search index...
The search index is not available
@cloud/document - v24.7.0
@cloud/document
"lock"
LockManager
Interface LockManager
分布式锁管理
interface
LockManager
{
isLocked
:
(
(
key
)
=>
boolean
)
;
lock
:
(
(
key
,
callback
,
option
?
)
=>
void
)
;
}
Index
Properties
is
Locked
lock
Properties
is
Locked
is
Locked
:
(
(
key
)
=>
boolean
)
查看键值是否被锁
Type declaration
(
key
)
:
boolean
Parameters
key
:
string
键值
Returns
boolean
lock
lock
:
(
(
key
,
callback
,
option
?
)
=>
void
)
对指定的键值进行上锁操作,成功则执行回调函数,执行完回调函数后释放锁。
Type declaration
(
key
,
callback
,
option
?
)
:
void
Parameters
key
:
string
键值
callback
:
callbackFn
回调函数
Optional
option
:
lockOption
分布锁参数
lockOption
Returns
void
Settings
Member Visibility
Protected
Inherited
Theme
OS
Light
Dark
On This Page
is
Locked
lock
@cloud/document - v24.7.0
Loading...
分布式锁管理