CoolFace
Apppublic

TrinetraLabs/Placebo_AI

sourceHugging Faceupdated 2mo agoView on Hugging Face
0likes
NodeBufferReader.js20 linesDownload Raw Back to reader
1"use strict";2var Uint8ArrayReader = require("./Uint8ArrayReader");3var utils = require("../utils");4 5function NodeBufferReader(data) {6    Uint8ArrayReader.call(this, data);7}8utils.inherits(NodeBufferReader, Uint8ArrayReader);9 10/**11 * @see DataReader.readData12 */13NodeBufferReader.prototype.readData = function(size) {14    this.checkOffset(size);15    var result = this.data.slice(this.zero + this.index, this.zero + this.index + size);16    this.index += size;17    return result;18};19module.exports = NodeBufferReader;20