META-INF.resources.bower_components.jszip.lib.reader.ArrayReader.min.js Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jwebmp-data-tables Show documentation
Show all versions of jwebmp-data-tables Show documentation
The JWebSwing implementation for Data Tables
"use strict";var DataReader=require("./DataReader");var utils=require("../utils");function ArrayReader(data){DataReader.call(this,data);for(var i=0;i=0;--i){if(this.data[i]===sig0&&this.data[i+1]===sig1&&this.data[i+2]===sig2&&this.data[i+3]===sig3){return i-this.zero}}return-1};ArrayReader.prototype.readAndCheckSignature=function(sig){var sig0=sig.charCodeAt(0),sig1=sig.charCodeAt(1),sig2=sig.charCodeAt(2),sig3=sig.charCodeAt(3),data=this.readData(4);return sig0===data[0]&&sig1===data[1]&&sig2===data[2]&&sig3===data[3]};ArrayReader.prototype.readData=function(size){this.checkOffset(size);if(size===0){return[]}var result=this.data.slice(this.zero+this.index,this.zero+this.index+size);this.index+=size;return result};module.exports=ArrayReader;
© 2015 - 2025 Weber Informatics LLC | Privacy Policy