/
var
/
www
/
greso.tech
/
server
/
nsm
/
node_modules
/
pdf-lib
/
es
/
core
/
streams
/
/var/www/greso.tech/server/nsm/node_modules/pdf-lib/es/core/streams
mkdir
upload
Name
Size
Mode
Actions
Ascii85Stream.d.ts
339
0644
edit
dl
rm
Ascii85Stream.d.ts.map
365
0644
edit
dl
rm
Ascii85Stream.js
2751
0644
edit
dl
rm
Ascii85Stream.js.map
2456
0644
edit
dl
rm
AsciiHexStream.d.ts
347
0644
edit
dl
rm
AsciiHexStream.d.ts.map
367
0644
edit
dl
rm
AsciiHexStream.js
2526
0644
edit
dl
rm
AsciiHexStream.js.map
1960
0644
edit
dl
rm
decode.d.ts
218
0644
edit
dl
rm
decode.d.ts.map
227
0644
edit
dl
rm
decode.js
2182
0644
edit
dl
rm
decode.js.map
2116
0644
edit
dl
rm
DecodeStream.d.ts
930
0644
edit
dl
rm
DecodeStream.d.ts.map
769
0644
edit
dl
rm
DecodeStream.js
4919
0644
edit
dl
rm
DecodeStream.js.map
4007
0644
edit
dl
rm
FlateStream.d.ts
433
0644
edit
dl
rm
FlateStream.d.ts.map
456
0644
edit
dl
rm
FlateStream.js
16422
0644
edit
dl
rm
FlateStream.js.map
15482
0644
edit
dl
rm
LZWStream.d.ts
431
0644
edit
dl
rm
LZWStream.d.ts.map
469
0644
edit
dl
rm
LZWStream.js
5336
0644
edit
dl
rm
LZWStream.js.map
4311
0644
edit
dl
rm
RunLengthStream.d.ts
326
0644
edit
dl
rm
RunLengthStream.d.ts.map
344
0644
edit
dl
rm
RunLengthStream.js
2059
0644
edit
dl
rm
RunLengthStream.js.map
1443
0644
edit
dl
rm
Stream.d.ts
1181
0644
edit
dl
rm
Stream.d.ts.map
1132
0644
edit
dl
rm
Stream.js
3349
0644
edit
dl
rm
Stream.js.map
2909
0644
edit
dl
rm
Edit:
/var/www/greso.tech/server/nsm/node_modules/pdf-lib/es/core/streams/RunLengthStream.js
(2059B)
/* * Copyright 2012 Mozilla Foundation * * The RunLengthStream class contained in this file is a TypeScript port of the * JavaScript RunLengthStream class in Mozilla's pdf.js project, made available * under the Apache 2.0 open source license. */ import { __extends } from "tslib"; import DecodeStream from "./DecodeStream"; var RunLengthStream = /** @class */ (function (_super) { __extends(RunLengthStream, _super); function RunLengthStream(stream, maybeLength) { var _this = _super.call(this, maybeLength) || this; _this.stream = stream; return _this; } RunLengthStream.prototype.readBlock = function () { // The repeatHeader has following format. The first byte defines type of run // and amount of bytes to repeat/copy: n = 0 through 127 - copy next n bytes // (in addition to the second byte from the header), n = 129 through 255 - // duplicate the second byte from the header (257 - n) times, n = 128 - end. var repeatHeader = this.stream.getBytes(2); if (!repeatHeader || repeatHeader.length < 2 || repeatHeader[0] === 128) { this.eof = true; return; } var buffer; var bufferLength = this.bufferLength; var n = repeatHeader[0]; if (n < 128) { // copy n bytes buffer = this.ensureBuffer(bufferLength + n + 1); buffer[bufferLength++] = repeatHeader[1]; if (n > 0) { var source = this.stream.getBytes(n); buffer.set(source, bufferLength); bufferLength += n; } } else { n = 257 - n; var b = repeatHeader[1]; buffer = this.ensureBuffer(bufferLength + n + 1); for (var i = 0; i < n; i++) { buffer[bufferLength++] = b; } } this.bufferLength = bufferLength; }; return RunLengthStream; }(DecodeStream)); export default RunLengthStream; //# sourceMappingURL=RunLengthStream.js.map
Save
cmd:
run