FileContentStorage
Class: FileContentStorage
Defined in: packages/utils/lib/content.d.ts:148
Local filesystem ContentStorage implementation
Implements
Constructors
Constructor
new FileContentStorage():
FileContentStorage
Returns
FileContentStorage
Properties
schemes
readonlyschemes:string[]
Defined in: packages/utils/lib/content.d.ts:149
Schemes handled, without ':' e.g. ["s3"], ["gs", "gcs"], ["file"]
Implementation of
Methods
deleteContent()
deleteContent(
url):Promise<void>
Defined in: packages/utils/lib/content.d.ts:181
Delete file
Parameters
url
string
file URL or path
Returns
Promise<void>
Implementation of
getContent()
getContent(
url,options?):Promise<Readable>
Defined in: packages/utils/lib/content.d.ts:156
Get content read stream
Parameters
url
string
file URL or path
options?
range options
Returns
Promise<Readable>
Readable stream
Implementation of
getWriteStream()
getWriteStream(
url):Promise<Writable>
Defined in: packages/utils/lib/content.d.ts:162
Get a write stream to the target path, creating parent directories if needed
Parameters
url
string
file URL or path
Returns
Promise<Writable>
Writable stream
headContent()
headContent(
url):Promise<ContentInfo>
Defined in: packages/utils/lib/content.d.ts:176
Head content metadata
Parameters
url
string
file URL or path
Returns
Promise<ContentInfo>
ContentInfo or undefined if not found
Implementation of
putContent()
putContent(
url,body,options?):Promise<ContentInfo>
Defined in: packages/utils/lib/content.d.ts:170
Put content atomically via temporary file and rename
Parameters
url
string
file URL or path
body
content to write
options?
write options
Returns
Promise<ContentInfo>
written ContentInfo