UNPKG

r2-lcp-js

Version:

Readium 2 LCP bits for NodeJS (TypeScript)

11 lines (10 loc) 708 B
import { Encrypted } from "../models/metadata-encrypted"; import { LCP } from "../parser/epub/lcp"; import { IStreamAndLength } from "r2-utils-js/dist/es5/src/_utils/zip/zip"; export interface ICryptoInfo { length: number; padding: number; } export declare function supports(lcp: LCP, _linkHref: string, linkPropertiesEncrypted: Encrypted): boolean; export declare function transformStream(lcp: LCP, linkHref: string, linkPropertiesEncrypted: Encrypted, stream: IStreamAndLength, isPartialByteRangeRequest: boolean, partialByteBegin: number, partialByteEnd: number): Promise<IStreamAndLength>; export declare function getDecryptedSizeStream(lcp: LCP, stream: IStreamAndLength): Promise<ICryptoInfo>;