mindee
Version:
Mindee Client Library for Node.js
17 lines (16 loc) • 439 B
JavaScript
import { OcrPage } from "./ocrPage.js";
export class MvisionV1 {
constructor(rawPrediction) {
/** List of words found on the page. */
this.pages = [];
rawPrediction["pages"].map((page) => {
this.pages.push(new OcrPage(page));
});
}
/**
* Default string representation.
*/
toString() {
return this.pages.map((page) => page.toString()).join("\n") + "\n";
}
}