@wxn0brp/db-core
Preparing search index...
types/action
ActionsBaseInterface
Interface ActionsBaseInterface
interface
ActionsBaseInterface
{
_inited
:
boolean
;
adapterOpts
:
AdapterOpts
;
smartExecutor
:
boolean
;
add
(
query
:
Add
)
:
Promise
<
DataInternal
>
;
beginTransaction
(
id
:
string
)
:
Promise
<
TransactionHandle
>
;
bulkAdd
(
query
:
BulkAdd
)
:
Promise
<
DataInternal
[]
>
;
close
(
...
args
:
any
[]
)
:
Promise
<
void
>
;
commitTransaction
(
handle
:
TransactionHandle
)
:
Promise
<
void
>
;
count
(
query
:
Count
)
:
Promise
<
number
>
;
createIndex
(
config
:
CreateIndex
)
:
Promise
<
void
>
;
ensureCollection
(
collection
:
string
)
:
Promise
<
boolean
>
;
find
(
query
:
Find
)
:
Promise
<
DataInternal
[]
>
;
findOne
(
query
:
FindOne
)
:
Promise
<
DataInternal
|
null
>
;
getCollections
()
:
Promise
<
string
[]
>
;
init
(
...
args
:
any
[]
)
:
Promise
<
void
>
;
issetCollection
(
collection
:
string
)
:
Promise
<
boolean
>
;
remove
(
query
:
Remove
)
:
Promise
<
DataInternal
[]
>
;
removeCollection
(
collection
:
string
)
:
Promise
<
boolean
>
;
removeIndex
(
config
:
RemoveIndex
)
:
Promise
<
void
>
;
removeOne
(
query
:
Remove
)
:
Promise
<
DataInternal
|
null
>
;
rollbackTransaction
(
handle
:
TransactionHandle
)
:
Promise
<
void
>
;
toggleOne
(
query
:
ToggleOne
)
:
Promise
<
ToggleOneResult
<
DataInternal
>
>
;
update
(
query
:
Update
)
:
Promise
<
DataInternal
[]
>
;
updateOne
(
query
:
Update
)
:
Promise
<
DataInternal
|
null
>
;
updateOneOrAdd
(
query
:
VQueryT
.
UpdateOneOrAdd
,
)
:
Promise
<
UpdateOneOrAddResult
<
DataInternal
>
>
;
}
Implemented by
ActionsBase
Index
Properties
_
inited
adapter
Opts
smart
Executor
Methods
add
begin
Transaction
bulk
Add
close
commit
Transaction
count
create
Index
ensure
Collection
find
find
One
get
Collections
init
isset
Collection
remove
remove
Collection
remove
Index
remove
One
rollback
Transaction
toggle
One
update
update
One
update
One
Or
Add
Properties
_
inited
_inited
:
boolean
adapter
Opts
adapterOpts
:
AdapterOpts
smart
Executor
smartExecutor
:
boolean
Methods
add
add
(
query
:
Add
)
:
Promise
<
DataInternal
>
Parameters
query
:
Add
Returns
Promise
<
DataInternal
>
begin
Transaction
beginTransaction
(
id
:
string
)
:
Promise
<
TransactionHandle
>
Parameters
id
:
string
Returns
Promise
<
TransactionHandle
>
bulk
Add
bulkAdd
(
query
:
BulkAdd
)
:
Promise
<
DataInternal
[]
>
Parameters
query
:
BulkAdd
Returns
Promise
<
DataInternal
[]
>
close
close
(
...
args
:
any
[]
)
:
Promise
<
void
>
Parameters
...
args
:
any
[]
Returns
Promise
<
void
>
commit
Transaction
commitTransaction
(
handle
:
TransactionHandle
)
:
Promise
<
void
>
Parameters
handle
:
TransactionHandle
Returns
Promise
<
void
>
count
count
(
query
:
Count
)
:
Promise
<
number
>
Parameters
query
:
Count
Returns
Promise
<
number
>
create
Index
createIndex
(
config
:
CreateIndex
)
:
Promise
<
void
>
Parameters
config
:
CreateIndex
Returns
Promise
<
void
>
ensure
Collection
ensureCollection
(
collection
:
string
)
:
Promise
<
boolean
>
Parameters
collection
:
string
Returns
Promise
<
boolean
>
find
find
(
query
:
Find
)
:
Promise
<
DataInternal
[]
>
Parameters
query
:
Find
Returns
Promise
<
DataInternal
[]
>
find
One
findOne
(
query
:
FindOne
)
:
Promise
<
DataInternal
|
null
>
Parameters
query
:
FindOne
Returns
Promise
<
DataInternal
|
null
>
get
Collections
getCollections
()
:
Promise
<
string
[]
>
Returns
Promise
<
string
[]
>
init
init
(
...
args
:
any
[]
)
:
Promise
<
void
>
Parameters
...
args
:
any
[]
Returns
Promise
<
void
>
isset
Collection
issetCollection
(
collection
:
string
)
:
Promise
<
boolean
>
Parameters
collection
:
string
Returns
Promise
<
boolean
>
remove
remove
(
query
:
Remove
)
:
Promise
<
DataInternal
[]
>
Parameters
query
:
Remove
Returns
Promise
<
DataInternal
[]
>
remove
Collection
removeCollection
(
collection
:
string
)
:
Promise
<
boolean
>
Parameters
collection
:
string
Returns
Promise
<
boolean
>
remove
Index
removeIndex
(
config
:
RemoveIndex
)
:
Promise
<
void
>
Parameters
config
:
RemoveIndex
Returns
Promise
<
void
>
remove
One
removeOne
(
query
:
Remove
)
:
Promise
<
DataInternal
|
null
>
Parameters
query
:
Remove
Returns
Promise
<
DataInternal
|
null
>
rollback
Transaction
rollbackTransaction
(
handle
:
TransactionHandle
)
:
Promise
<
void
>
Parameters
handle
:
TransactionHandle
Returns
Promise
<
void
>
toggle
One
toggleOne
(
query
:
ToggleOne
)
:
Promise
<
ToggleOneResult
<
DataInternal
>
>
Parameters
query
:
ToggleOne
Returns
Promise
<
ToggleOneResult
<
DataInternal
>
>
update
update
(
query
:
Update
)
:
Promise
<
DataInternal
[]
>
Parameters
query
:
Update
Returns
Promise
<
DataInternal
[]
>
update
One
updateOne
(
query
:
Update
)
:
Promise
<
DataInternal
|
null
>
Parameters
query
:
Update
Returns
Promise
<
DataInternal
|
null
>
update
One
Or
Add
updateOneOrAdd
(
query
:
VQueryT
.
UpdateOneOrAdd
,
)
:
Promise
<
UpdateOneOrAddResult
<
DataInternal
>
>
Parameters
query
:
VQueryT
.
UpdateOneOrAdd
Returns
Promise
<
UpdateOneOrAddResult
<
DataInternal
>
>
Settings
Member Visibility
Protected
Inherited
External
Theme
OS
Light
Dark
On This Page
Properties
_
inited
adapter
Opts
smart
Executor
Methods
add
begin
Transaction
bulk
Add
close
commit
Transaction
count
create
Index
ensure
Collection
find
find
One
get
Collections
init
isset
Collection
remove
remove
Collection
remove
Index
remove
One
rollback
Transaction
toggle
One
update
update
One
update
One
Or
Add
@wxn0brp/db-core
Loading...