@injectable/file-hosting-service
v2.0.0
Published
service for hosting files with compress option
Readme
File Hosting Service
Service for hosting files with compress option.
This package works with the Injectable Core.
Functions
Registers an id for a file.
public registerFileId(): numberHosts an node buffer on a route.
public setFile(
injectableName: string,
fileId: number,
route: string,
buffer: Buffer,
encodings: Array<Encoding>,
onRequest?: OnRequest
): numberHosts the file from the path on a route.
public setFileFromPath(
injectableName: string,
fileId: number,
route: string,
path: string,
encodings: Array<Encoding>,
onRequest?: OnRequest
): numberDeletes the file (also the path) wth the given id.
public deleteFile(
injectableName: string,
fileId: number
): voidLicense
See the LICENSE file for license rights and limitations (MIT).
