Interface: DBConnection
@divine/uri.DBDriver.DBConnection
Properties
state
• Readonly
state: "open"
| "closed"
Defined in
Methods
close
▸ close(): Promise
<void
>
Returns
Promise
<void
>
Defined in
open
▸ open(): Promise
<void
>
Returns
Promise
<void
>
Defined in
ping
▸ ping(timeout
): Promise
<void
>
Parameters
Name | Type |
---|---|
timeout | number |
Returns
Promise
<void
>
Defined in
query
▸ query(...queries
): Promise
<DBResult
[]>
Parameters
Name | Type |
---|---|
...queries | DBQuery [] |
Returns
Promise
<DBResult
[]>
Defined in
reference
▸ reference(dbURI
): DBReference
| Promise
<DBReference
>
Parameters
Name | Type |
---|---|
dbURI | DatabaseURI |
Returns
DBReference
| Promise
<DBReference
>
Defined in
transaction
▸ transaction<T
>(dtp
, cb
): Promise
<T
>
Type parameters
Name |
---|
T |
Parameters
Name | Type |
---|---|
dtp | DBTransactionParams |
cb | DBCallback <T > |
Returns
Promise
<T
>
Defined in
watch
▸ Optional
watch(query
): AsyncIterable
<DBResult
>
Parameters
Name | Type |
---|---|
query | DBQuery |
Returns
AsyncIterable
<DBResult
>