UNPKG

@nos-sdk/nos-node-sdk

Version:

NOS Node.js SDK实现了NOS对象操作接口,基于此SDK能方便快速地实现JavaScript应用程序来使用NOS的对象存储服务。

26 lines (25 loc) 1.37 kB
/// <reference types="node" /> /// <reference types="ramda" /> import { Headers } from 'node-fetch'; import { ObjectMetadata } from '../type/object'; import ReadableStream = NodeJS.ReadableStream; export declare function camelCase(name: string): string; export declare function CamelCase(name: string): string; export declare function kababCase(name: string): string; export declare const camelCaseObject: (obj: any) => any; export declare const CamelCaseObject: (obj: any) => any; export declare const kababCaseObject: (obj: any) => any; export declare function stream2Buffer(stream: ReadableStream): Promise<Buffer>; export declare const addMetadataPrefix: (obj: object) => object; export declare function getMetadataFromHeaders(headers: Headers): ObjectMetadata; export declare function isHttpStatusOk(status: number): boolean; export declare function md5sum(data: Buffer | string): string; export declare const isNullOrUndefined: (a: any) => boolean; export declare const compactObject: import("ramda").FilterOnceApplied<any>; export declare function applyMixins(derivedCtor: any, baseCtors: any[]): void; export declare function Callbackable(target: any, key: string, descr: PropertyDescriptor): void; export declare function normalizeArray(value: any): Array<any>; /** * @param key */ export declare function encodeKey(key: string): string;