/
var
/
www
/
greso.tech
/
server
/
nsm
/
node_modules
/
pdf-lib
/
cjs
/
core
/
streams
/
/var/www/greso.tech/server/nsm/node_modules/pdf-lib/cjs/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
2876
0644
edit
dl
rm
Ascii85Stream.js.map
2450
0644
edit
dl
rm
AsciiHexStream.d.ts
347
0644
edit
dl
rm
AsciiHexStream.d.ts.map
367
0644
edit
dl
rm
AsciiHexStream.js
2651
0644
edit
dl
rm
AsciiHexStream.js.map
1954
0644
edit
dl
rm
decode.d.ts
218
0644
edit
dl
rm
decode.d.ts.map
227
0644
edit
dl
rm
decode.js
2818
0644
edit
dl
rm
decode.js.map
1995
0644
edit
dl
rm
DecodeStream.d.ts
930
0644
edit
dl
rm
DecodeStream.d.ts.map
769
0644
edit
dl
rm
DecodeStream.js
5062
0644
edit
dl
rm
DecodeStream.js.map
3979
0644
edit
dl
rm
FlateStream.d.ts
433
0644
edit
dl
rm
FlateStream.d.ts.map
456
0644
edit
dl
rm
FlateStream.js
16547
0644
edit
dl
rm
FlateStream.js.map
15476
0644
edit
dl
rm
LZWStream.d.ts
431
0644
edit
dl
rm
LZWStream.d.ts.map
469
0644
edit
dl
rm
LZWStream.js
5461
0644
edit
dl
rm
LZWStream.js.map
4305
0644
edit
dl
rm
RunLengthStream.d.ts
326
0644
edit
dl
rm
RunLengthStream.d.ts.map
344
0644
edit
dl
rm
RunLengthStream.js
2184
0644
edit
dl
rm
RunLengthStream.js.map
1437
0644
edit
dl
rm
Stream.d.ts
1181
0644
edit
dl
rm
Stream.d.ts.map
1132
0644
edit
dl
rm
Stream.js
3429
0644
edit
dl
rm
Stream.js.map
2912
0644
edit
dl
rm
Edit:
/var/www/greso.tech/server/nsm/node_modules/pdf-lib/cjs/core/streams/Stream.js
(3429B)
"use strict"; /* * Copyright 2012 Mozilla Foundation * * The Stream class contained in this file is a TypeScript port of the * JavaScript Stream class in Mozilla's pdf.js project, made available * under the Apache 2.0 open source license. */ Object.defineProperty(exports, "__esModule", { value: true }); var Stream = /** @class */ (function () { function Stream(buffer, start, length) { this.bytes = buffer; this.start = start || 0; this.pos = this.start; this.end = !!start && !!length ? start + length : this.bytes.length; } Object.defineProperty(Stream.prototype, "length", { get: function () { return this.end - this.start; }, enumerable: false, configurable: true }); Object.defineProperty(Stream.prototype, "isEmpty", { get: function () { return this.length === 0; }, enumerable: false, configurable: true }); Stream.prototype.getByte = function () { if (this.pos >= this.end) { return -1; } return this.bytes[this.pos++]; }; Stream.prototype.getUint16 = function () { var b0 = this.getByte(); var b1 = this.getByte(); if (b0 === -1 || b1 === -1) { return -1; } return (b0 << 8) + b1; }; Stream.prototype.getInt32 = function () { var b0 = this.getByte(); var b1 = this.getByte(); var b2 = this.getByte(); var b3 = this.getByte(); return (b0 << 24) + (b1 << 16) + (b2 << 8) + b3; }; // Returns subarray of original buffer, should only be read. Stream.prototype.getBytes = function (length, forceClamped) { if (forceClamped === void 0) { forceClamped = false; } var bytes = this.bytes; var pos = this.pos; var strEnd = this.end; if (!length) { var subarray = bytes.subarray(pos, strEnd); // `this.bytes` is always a `Uint8Array` here. return forceClamped ? new Uint8ClampedArray(subarray) : subarray; } else { var end = pos + length; if (end > strEnd) { end = strEnd; } this.pos = end; var subarray = bytes.subarray(pos, end); // `this.bytes` is always a `Uint8Array` here. return forceClamped ? new Uint8ClampedArray(subarray) : subarray; } }; Stream.prototype.peekByte = function () { var peekedByte = this.getByte(); this.pos--; return peekedByte; }; Stream.prototype.peekBytes = function (length, forceClamped) { if (forceClamped === void 0) { forceClamped = false; } var bytes = this.getBytes(length, forceClamped); this.pos -= bytes.length; return bytes; }; Stream.prototype.skip = function (n) { if (!n) { n = 1; } this.pos += n; }; Stream.prototype.reset = function () { this.pos = this.start; }; Stream.prototype.moveStart = function () { this.start = this.pos; }; Stream.prototype.makeSubStream = function (start, length) { return new Stream(this.bytes, start, length); }; Stream.prototype.decode = function () { return this.bytes; }; return Stream; }()); exports.default = Stream; //# sourceMappingURL=Stream.js.map
Save
cmd:
run