mindee
Version:
Mindee Client Library for Node.js
20 lines (19 loc) • 622 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.BufferInput = void 0;
const localInputSource_1 = require("./localInputSource");
const inputSource_1 = require("./inputSource");
class BufferInput extends localInputSource_1.LocalInputSource {
constructor({ buffer, filename }) {
super({
inputType: inputSource_1.INPUT_TYPE_BUFFER,
});
this.fileObject = buffer;
this.filename = filename;
}
async init() {
this.mimeType = await this.checkMimetype();
this.initialized = true;
}
}
exports.BufferInput = BufferInput;