Skip to main content

FileBinaryParameters

@webda/fs


Class: FileBinaryParameters

Defined in: fs/src/filebinary.service.ts:55

Configuration parameters for the filesystem-backed binary storage service.

Extends​

  • CloudBinaryParameters

Constructors​

Constructor​

new FileBinaryParameters(): FileBinaryParameters

Returns​

FileBinaryParameters

Inherited from​

CloudBinaryParameters.constructor

Properties​

_maxFileSize​

protected _maxFileSize: number

Defined in: core/lib/services/binary.service.d.ts:660

max file size

Inherited from​

CloudBinaryParameters._maxFileSize


_maxUploadSize?​

protected optional _maxUploadSize?: number

Defined in: core/lib/services/binary.service.d.ts:661

Inherited from​

CloudBinaryParameters._maxUploadSize


contentStorage?​

optional contentStorage?: object

Defined in: core/lib/services/cloudbinary.d.ts:10

default?​

optional default?: boolean

register?​

optional register?: boolean

Inherited from​

CloudBinaryParameters.contentStorage


folder​

folder: string

Defined in: fs/src/filebinary.service.ts:59

Define the folder to store objects in


maxSize​

maxSize: number

Defined in: fs/src/filebinary.service.ts:64

Maximum size to handle

Default​

10485760

models​

models: object

Defined in: core/lib/services/binary.service.d.ts:675

Define the map of models

  • indicates all models

key is a Store name the string[] represent all valids attributes to store files in * indicates all attributes

Index Signature​

[key: string]: string[]

Inherited from​

CloudBinaryParameters.models


prefix?​

optional prefix?: string

Defined in: core/lib/services/cloudbinary.d.ts:9

Inherited from​

CloudBinaryParameters.prefix


type​

type: string

Defined in: core/lib/services/serviceparameters.d.ts:9

Type of the service

Inherited from​

CloudBinaryParameters.type


url?​

optional url?: string

Defined in: fs/src/filebinary.service.ts:68

URL to use for direct download


urlExpiry​

urlExpiry: number

Defined in: core/lib/services/binary.service.d.ts:667

Lifetime in seconds of the signed URLs

Default​

30

Inherited from​

CloudBinaryParameters.urlExpiry

Accessors​

maxFileSize​

Get Signature​

get maxFileSize(): number

Defined in: core/lib/services/binary.service.d.ts:697

Get the max file size in bytes

Returns​

number

the result number

Set Signature​

set maxFileSize(value): void

Defined in: core/lib/services/binary.service.d.ts:683

Define the maximum filesize to accept as direct upload

Default​
10 MB
Parameters​
value​

string | number

Returns​

void

Inherited from​

CloudBinaryParameters.maxFileSize


maxUploadSize​

Get Signature​

get maxUploadSize(): number | undefined

Defined in: core/lib/services/binary.service.d.ts:688

Maximum size accepted for a direct-to-bucket upload, undefined means no limit

Returns​

number | undefined

the limit in bytes or undefined

Set Signature​

set maxUploadSize(value): void

Defined in: core/lib/services/binary.service.d.ts:692

Maximum size accepted for a direct-to-bucket upload, undefined means no limit

Parameters​
value​

string | number | undefined

Returns​

void

Inherited from​

CloudBinaryParameters.maxUploadSize

Methods​

load()​

load(params): this

Defined in: fs/src/filebinary.service.ts:76

Load and normalize parameters, ensuring the folder path has a trailing slash.

Parameters​

params​

any

raw parameter values

Returns​

this

this instance for chaining

Overrides​

CloudBinaryParameters.load


update()​

update(params, delta): this

Defined in: core/lib/application/parameters.d.ts:21

Update parameters and call watchers if a parameter was changed

Parameters​

params​

any

the service parameters

delta​

any

the delta

Returns​

this

this for chaining

Inherited from​

CloudBinaryParameters.update


with()​

with(callback): this

Defined in: core/lib/application/parameters.d.ts:27

Watch for changes on the parameters and call watchers when a parameter is changed

Parameters​

callback​

(params) => void

the callback function

Returns​

this

this for chaining

Inherited from​

CloudBinaryParameters.with