ImgProcDataAdapter
このコンテンツはまだ日本語訳がありません。
Data adapter
Properties
close()
close: () =>
void
|Promise
<void
>
Close database
Returns
void
| Promise
<void
>
Defined in
countdown()
countdown: () =>
void
|Promise
<void
>
Countdown all records
Returns
void
| Promise
<void
>
Defined in
delete()
delete: (
criteria
) =>void
|Promise
<void
>
Delete the record
Parameters
• criteria: ImgProcDataAdapterCriteria
Returns
void
| Promise
<void
>
Defined in
deleteExpiredRecords()
deleteExpiredRecords: (
now
) =>null
|Promise
<null
> |Set
<string
> |Promise
<Set
<string
>>
Parameters
• now: number
Unixtime (milliseconds)
Returns
null
| Promise
<null
> | Set
<string
> | Promise
<Set
<string
>>
Deleted hashes or null
Defined in
fetch()
fetch: (
criteria
) =>null
|ImgProcFileRecord
|Promise
<ImgProcFileRecord
> |Promise
<null
>
Fetch single record
- To fetch a record with category
source
, specifyhash
. - To fetch a record with category
variant
orplaceholder
, specifysource
andprofile
.
Parameters
• criteria: ImgProcDataAdapterCriteria
Returns
null
| ImgProcFileRecord
| Promise
<ImgProcFileRecord
> | Promise
<null
>
Defined in
initialize()
initialize: (
options
) =>void
|Promise
<void
>
Initialize database
Parameters
• options: ImgProcDataAdapterInitOptions
Returns
void
| Promise
<void
>
Defined in
insert()
insert: (
data
) =>void
|Promise
<void
>
Insert the record
Parameters
• data: ImgProcFile
Returns
void
| Promise
<void
>
Defined in
list()
list: () =>
Set
<string
> |Promise
<Set
<string
>>
List all hashes
Returns
Set
<string
> | Promise
<Set
<string
>>
Defined in
renew()
renew: (
criteria
) =>void
|Promise
<void
>
Renew the record
Parameters
• criteria: ImgProcDataAdapterCriteria
Returns
void
| Promise
<void
>
Defined in
updateMetadata()
updateMetadata: (
data
) =>void
|Promise
<void
>
Update the record for remote file
Parameters
• data
• data.b?: number
• data.expiresAt?: number
• data.format: string
• data.g?: number
• data.hash: string
• data.height: number
• data.r?: number
• data.width: number
Returns
void
| Promise
<void
>