Skip to main content

ContentStorage

@webda/utils


Interface: ContentStorage

Defined in: packages/utils/src/content.ts:71

Content storage interface

Properties​

schemes​

readonly schemes: string[]

Defined in: packages/utils/src/content.ts:73

Schemes handled, without ':' e.g. ["s3"], ["gs", "gcs"], ["file"]

Methods​

deleteContent()?​

optional deleteContent(url): Promise<void>

Defined in: packages/utils/src/content.ts:89

Delete content

Parameters​

url​

string

Returns​

Promise<void>


getContent()​

getContent(url, options?): Promise<Readable>

Defined in: packages/utils/src/content.ts:77

Get the content

Parameters​

url​

string

options?​

ContentGetOptions

Returns​

Promise<Readable>


headContent()?​

optional headContent(url): Promise<ContentInfo | undefined>

Defined in: packages/utils/src/content.ts:85

Perform head content

Parameters​

url​

string

Returns​

Promise<ContentInfo | undefined>


putContent()​

putContent(url, body, options?): Promise<ContentInfo>

Defined in: packages/utils/src/content.ts:81

Put content

Parameters​

url​

string

body​

ContentBody

options?​

ContentPutOptions

Returns​

Promise<ContentInfo>