Loading demo/download.js +1 −1 Original line number Diff line number Diff line Loading @@ -63,7 +63,7 @@ export class BlobStore { * Downloads the file from the given URL and saves it to this BlobStore. * * @param {string} url - URL of the file to download. * @returns {blob} Blob containing the downloaded data. * @returns {Promise<Blob>} Blob containing the downloaded data. */ async download(url) { let filename = url.split("/").pop(); Loading src/common.ts +1 −1 Original line number Diff line number Diff line Loading @@ -36,7 +36,7 @@ export function setDebugLevel(level: DebugLevel) { * Reads all of the data in the given blob and returns it as an ArrayBuffer. * * @param {Blob} blob - Blob with the data to read. * @returns {buffer} ArrayBuffer containing data from the blob. * @returns {Promise<ArrayBuffer>} ArrayBuffer containing data from the blob. * @ignore */ export function readBlobAsBuffer(blob: Blob): Promise<ArrayBuffer> { Loading src/fastboot.ts +5 −5 Original line number Diff line number Diff line Loading @@ -276,7 +276,7 @@ export class FastbootDevice { * Read a raw command response from the bootloader. * * @private * @returns {response} Object containing response text and data size, if any. * @returns {Promise<CommandResponse>} Object containing response text and data size, if any. * @throws {FastbootError} */ private async readResponse() { Loading Loading @@ -311,11 +311,11 @@ export class FastbootDevice { } /** * Send a textual command to the bootloader. * Send a textual command to the bootloader and read the response. * This is in raw fastboot format, not AOSP fastboot syntax. * * @param {string} command - The command to send. * @returns {response} Object containing response text and data size, if any. * @returns {Promise<CommandResponse>} Object containing response text and data size, if any. * @throws {FastbootError} */ async runCommand(command: string) { Loading @@ -337,7 +337,7 @@ export class FastbootDevice { * does not exist. * * @param {string} varName - The name of the variable to get. * @returns {value} Textual content of the variable. * @returns {Promise<string>} Textual content of the variable. * @throws {FastbootError} */ async getVariable(varName: string) { Loading Loading @@ -369,7 +369,7 @@ export class FastbootDevice { * Get the maximum download size for a single payload, in bytes. * * @private * @returns {downloadSize} * @returns {Promise<number>} * @throws {FastbootError} */ private async getDownloadSize() { Loading src/sparse.ts +2 −2 Original line number Diff line number Diff line Loading @@ -48,7 +48,7 @@ export interface SparseChunk { * Returns a parsed version of the sparse image file header from the given buffer. * * @param {ArrayBuffer} buffer - Raw file header data. * @returns {header} Object containing the header information. * @returns {SparseHeader} Object containing the header information. */ export function parseFileHeader(buffer: ArrayBuffer) { let view = new DataView(buffer); Loading Loading @@ -169,7 +169,7 @@ function createImage(header: SparseHeader, chunks: Array<SparseChunk>) { * Creates a sparse image from buffer containing raw image data. * * @param {ArrayBuffer} rawBuffer - Buffer containing the raw image data. * @returns {sparseBuffer} Buffer containing the new sparse image. * @returns {ArrayBuffer} Buffer containing the new sparse image. */ export function fromRaw(rawBuffer: ArrayBuffer) { let header = { Loading Loading
demo/download.js +1 −1 Original line number Diff line number Diff line Loading @@ -63,7 +63,7 @@ export class BlobStore { * Downloads the file from the given URL and saves it to this BlobStore. * * @param {string} url - URL of the file to download. * @returns {blob} Blob containing the downloaded data. * @returns {Promise<Blob>} Blob containing the downloaded data. */ async download(url) { let filename = url.split("/").pop(); Loading
src/common.ts +1 −1 Original line number Diff line number Diff line Loading @@ -36,7 +36,7 @@ export function setDebugLevel(level: DebugLevel) { * Reads all of the data in the given blob and returns it as an ArrayBuffer. * * @param {Blob} blob - Blob with the data to read. * @returns {buffer} ArrayBuffer containing data from the blob. * @returns {Promise<ArrayBuffer>} ArrayBuffer containing data from the blob. * @ignore */ export function readBlobAsBuffer(blob: Blob): Promise<ArrayBuffer> { Loading
src/fastboot.ts +5 −5 Original line number Diff line number Diff line Loading @@ -276,7 +276,7 @@ export class FastbootDevice { * Read a raw command response from the bootloader. * * @private * @returns {response} Object containing response text and data size, if any. * @returns {Promise<CommandResponse>} Object containing response text and data size, if any. * @throws {FastbootError} */ private async readResponse() { Loading Loading @@ -311,11 +311,11 @@ export class FastbootDevice { } /** * Send a textual command to the bootloader. * Send a textual command to the bootloader and read the response. * This is in raw fastboot format, not AOSP fastboot syntax. * * @param {string} command - The command to send. * @returns {response} Object containing response text and data size, if any. * @returns {Promise<CommandResponse>} Object containing response text and data size, if any. * @throws {FastbootError} */ async runCommand(command: string) { Loading @@ -337,7 +337,7 @@ export class FastbootDevice { * does not exist. * * @param {string} varName - The name of the variable to get. * @returns {value} Textual content of the variable. * @returns {Promise<string>} Textual content of the variable. * @throws {FastbootError} */ async getVariable(varName: string) { Loading Loading @@ -369,7 +369,7 @@ export class FastbootDevice { * Get the maximum download size for a single payload, in bytes. * * @private * @returns {downloadSize} * @returns {Promise<number>} * @throws {FastbootError} */ private async getDownloadSize() { Loading
src/sparse.ts +2 −2 Original line number Diff line number Diff line Loading @@ -48,7 +48,7 @@ export interface SparseChunk { * Returns a parsed version of the sparse image file header from the given buffer. * * @param {ArrayBuffer} buffer - Raw file header data. * @returns {header} Object containing the header information. * @returns {SparseHeader} Object containing the header information. */ export function parseFileHeader(buffer: ArrayBuffer) { let view = new DataView(buffer); Loading Loading @@ -169,7 +169,7 @@ function createImage(header: SparseHeader, chunks: Array<SparseChunk>) { * Creates a sparse image from buffer containing raw image data. * * @param {ArrayBuffer} rawBuffer - Buffer containing the raw image data. * @returns {sparseBuffer} Buffer containing the new sparse image. * @returns {ArrayBuffer} Buffer containing the new sparse image. */ export function fromRaw(rawBuffer: ArrayBuffer) { let header = { Loading