Lines Matching full:input

22 exports.encode = function(input) {  argument
25 var i = 0, len = input.length, remainingBytes = len;
27 var isArray = utils.getTypeOf(input) !== "string";
28 while (i < input.length) {
32 chr1 = input.charCodeAt(i++);
33 chr2 = i < len ? input.charCodeAt(i++) : 0;
34 chr3 = i < len ? input.charCodeAt(i++) : 0;
36 chr1 = input[i++];
37 chr2 = i < len ? input[i++] : 0;
38 chr3 = i < len ? input[i++] : 0;
54 exports.decode = function(input) { argument
61 if (input.substr(0, dataUrlPrefix.length) === dataUrlPrefix) {
65 // We can detect that the string input looks like a data url but we
68 throw new Error("Invalid base64 input, it looks like a data url.");
71 input = input.replace(/[^A-Za-z0-9+/=]/g, "");
73 var totalLength = input.length * 3 / 4;
74 if(input.charAt(input.length - 1) === _keyStr.charAt(64)) {
77 if(input.charAt(input.length - 2) === _keyStr.charAt(64)) {
83 // - the input is not a base64 content
84 // - the input is *almost* a base64 content, with a extra chars at the
86 // - the input uses a base64 variant (base64url for example)
87 throw new Error("Invalid base64 input, bad content length.");
96 while (i < input.length) {
98 enc1 = _keyStr.indexOf(input.charAt(i++));
99 enc2 = _keyStr.indexOf(input.charAt(i++));
100 enc3 = _keyStr.indexOf(input.charAt(i++));
101 enc4 = _keyStr.indexOf(input.charAt(i++));
278 module.exports = function crc32wrapper(input, crc) { argument
279 if (typeof input === "undefined" || !input.length) {
283 var isArray = utils.getTypeOf(input) !== "string";
286 return crc32(crc|0, input, input.length, 0);
288 return crc32str(crc|0, input, input.length, 0);
1132 var input = files[i];
1134 var unsafeName = input.fileNameStr;
1135 var safeName = utils.resolve(input.fileNameStr);
1137 zip.file(safeName, input.decompressed, {
1140 date: input.date,
1141 dir: input.dir,
1142 comment: input.fileCommentStr.length ? input.fileCommentStr : null,
1143 unixPermissions: input.unixPermissions,
1144 dosPermissions: input.dosPermissions,
1147 if (!input.dir) {
1172 GenericWorker.call(this, "Nodejs stream input adapter for " + filename);
3107 * @param {Object} input the input.
3108 * @return {Object} the same input.
3110 function identity(input) { argument
3111 return input;
3259 "array": function(input) { argument
3260 return stringToArrayLike(input, new Array(input.length));
3262 "arraybuffer": function(input) { argument
3263 return transform["string"]["uint8array"](input).buffer;
3265 "uint8array": function(input) { argument
3266 return stringToArrayLike(input, new Uint8Array(input.length));
3268 "nodebuffer": function(input) { argument
3269 return stringToArrayLike(input, nodejsUtils.allocBuffer(input.length));
3277 "arraybuffer": function(input) { argument
3278 return (new Uint8Array(input)).buffer;
3280 "uint8array": function(input) { argument
3281 return new Uint8Array(input);
3283 "nodebuffer": function(input) { argument
3284 return nodejsUtils.newBufferFrom(input);
3290 "string": function(input) { argument
3291 return arrayLikeToString(new Uint8Array(input));
3293 "array": function(input) { argument
3294 return arrayLikeToArrayLike(new Uint8Array(input), new Array(input.byteLength));
3297 "uint8array": function(input) { argument
3298 return new Uint8Array(input);
3300 "nodebuffer": function(input) { argument
3301 return nodejsUtils.newBufferFrom(new Uint8Array(input));
3308 "array": function(input) { argument
3309 return arrayLikeToArrayLike(input, new Array(input.length));
3311 "arraybuffer": function(input) { argument
3312 return input.buffer;
3315 "nodebuffer": function(input) { argument
3316 return nodejsUtils.newBufferFrom(input);
3323 "array": function(input) { argument
3324 return arrayLikeToArrayLike(input, new Array(input.length));
3326 "arraybuffer": function(input) { argument
3327 return transform["nodebuffer"]["uint8array"](input).buffer;
3329 "uint8array": function(input) { argument
3330 return arrayLikeToArrayLike(input, new Uint8Array(input.length));
3336 * Transform an input into any type.
3338 * If no output type is specified, the unmodified input will be returned.
3340 * @param {String|Array|ArrayBuffer|Uint8Array|Buffer} input the input to convert.
3343 exports.transformTo = function(outputType, input) { argument
3344 if (!input) {
3347 input = "";
3350 return input;
3353 var inputType = exports.getTypeOf(input);
3354 var result = transform[inputType][outputType](input);
3384 * Return the type of the input.
3386 * @param {Object} input the input to identify.
3387 * @return {String} the (lowercase) type of the input.
3389 exports.getTypeOf = function(input) { argument
3390 if (typeof input === "string") {
3393 if (Object.prototype.toString.call(input) === "[object Array]") {
3396 if (support.nodebuffer && nodejsUtils.isBuffer(input)) {
3399 if (support.uint8array && input instanceof Uint8Array) {
3402 if (support.arraybuffer && input instanceof ArrayBuffer) {
4790 * - data (Uint8Array|Array|ArrayBuffer|String): input data. Strings will be
4795 * Sends input data to deflate pipe, generating [[Deflate#onData]] calls with
4803 * We strongly recommend to use `Uint8Array` on input for best speed (output
4829 strm.input = strings.string2buf(data);
4831 strm.input = new Uint8Array(data);
4833 strm.input = data;
4837 strm.avail_in = strm.input.length;
4899 * Called once after you tell deflate that the input stream is
4921 * - data (Uint8Array|Array|String): input data to compress.
4953 function deflate(input, options) { argument
4956 deflator.push(input, true);
4967 * - data (Uint8Array|Array|String): input data to compress.
4973 function deflateRaw(input, options) { argument
4976 return deflate(input, options);
4982 * - data (Uint8Array|Array|String): input data to compress.
4988 function gzip(input, options) { argument
4991 return deflate(input, options);
5151 * - data (Uint8Array|Array|ArrayBuffer|String): input data
5155 * Sends input data to inflate pipe, generating [[Inflate#onData]] calls with
5163 * We strongly recommend to use `Uint8Array` on input for best speed (output
5195 strm.input = strings.binstring2buf(data);
5197 strm.input = new Uint8Array(data);
5199 strm.input = data;
5203 strm.avail_in = strm.input.length;
5262 // When no more input data, we should check that internal inflate buffers
5317 * Called either after you tell inflate that the input stream is
5341 * - data (Uint8Array|Array|String): input data to decompress.
5368 * , input = pako.deflate([1,2,3,4,5,6,7,8,9])
5372 * output = pako.inflate(input);
5378 function inflate(input, options) { argument
5381 inflator.push(input, true);
5392 * - data (Uint8Array|Array|String): input data to decompress.
5398 function inflateRaw(input, options) { argument
5401 return inflate(input, options);
5407 * - data (Uint8Array|Array|String): input data to decompress.
6013 var BS_NEED_MORE = 1; /* block not completed, need more input or more output */
6016 var BS_FINISH_DONE = 4; /* finish done, accept no more input or output */
6086 * Read a new buffer from the current input stream, update the adler32
6087 * and total number of bytes read. All deflate() input goes through
6089 * allocating a large strm->input buffer and copying from it.
6101 utils.arraySet(buf, strm.input, strm.next_in, len, start);
6158 /* Do not look for matches beyond the end of the input. This is necessary
6256 // * strstart == 0 && lookahead == 1 (input done a byte at time)
6319 /* Initialize the hash value now that we have some input: */
6342 /* If the whole input has less than MIN_MATCH bytes, ins_h is garbage,
6387 * Copy without compression as much as possible from the input stream, return
6405 /* Copy as much as possible from input to output: */
6487 * Compress as much as possible from the input stream, return the current
6499 * at the end of the input file. We need MAX_MATCH bytes
6531 * of the string with itself at the start of the input file).
6627 /* Process the input block. */
6630 * at the end of the input file. We need MAX_MATCH bytes
6664 * of the string with itself at the start of the input file).
6792 * at the end of the input file. We need MAX_MATCH bytes
7005 /* Sliding window. Input bytes are read into the second half of the window,
7013 /* Actual size of window: 2*wSize, except when the user input buffer
7031 /* Number of bits by which ins_h must be shifted at each input
7126 * - if compression is not successful for the first block, all input
7128 * when input comes from standard input. (This can also be done for
7134 * adaptation to changes in the input data statistics. (Take for
7170 * longest match routines access bytes past the input. This is then
7317 (!strm.input && strm.avail_in !== 0) ||
7549 /* User must not provide more input after the first FINISH: */
7676 var input;
7717 input = strm.input;
7720 strm.input = dictionary;
7745 strm.input = input;
7859 literal and match bytes until either not enough input or output is
7861 When large enough input and output buffers are supplied to inflate(), for
7862 example, a 16K input buffer and a 64K output buffer, more than 95% of the
7875 LEN -- ran out of enough output space or enough available input
7881 - The maximum input bits used by a length/distance pair is 15 bits for the
7884 Therefore if strm.avail_in >= 6, then there is enough input to avoid
7885 checking for available input while decoding.
7894 var _in; /* local strm.input */
7895 var last; /* have enough input while in < last */
7922 var input, output; // JS specific, because we have no pointers
7928 input = strm.input;
7950 input data or output space */
7955 hold += input[_in++] << bits;
7957 hold += input[_in++] << bits;
7980 hold += input[_in++] << bits;
7989 hold += input[_in++] << bits;
7991 hold += input[_in++] << bits;
8007 hold += input[_in++] << bits;
8010 hold += input[_in++] << bits;
8260 var COPY = 16; /* i/o: waiting for input or output to copy stored block */
8319 this.hold = 0; /* input bit accumulator */
8561 var input, output; // input/output buffers
8562 var next; /* next input INDEX */
8564 var have, left; /* available input and output */
8567 var _in, _out; /* save starting available input and output */
8587 (!strm.input && strm.avail_in !== 0)) {
8600 input = strm.input;
8622 hold += input[next++] << bits;
8683 hold += input[next++] << bits;
8719 hold += input[next++] << bits;
8746 hold += input[next++] << bits;
8773 hold += input[next++] << bits;
8811 input,
8824 state.check = crc32(state.check, input, copy, next);
8841 len = input[next + copy++];
8850 state.check = crc32(state.check, input, copy, next);
8867 len = input[next + copy++];
8875 state.check = crc32(state.check, input, copy, next);
8892 hold += input[next++] << bits;
8918 hold += input[next++] << bits;
8960 hold += input[next++] << bits;
9012 hold += input[next++] << bits;
9041 utils.arraySet(output, input, next, copy, put);
9058 hold += input[next++] << bits;
9094 hold += input[next++] << bits;
9139 hold += input[next++] << bits;
9157 hold += input[next++] << bits;
9183 hold += input[next++] << bits;
9204 hold += input[next++] << bits;
9297 input = strm.input;
9319 hold += input[next++] << bits;
9338 hold += input[next++] << bits;
9382 hold += input[next++] << bits;
9408 hold += input[next++] << bits;
9427 hold += input[next++] << bits;
9458 hold += input[next++] << bits;
9542 hold |= input[next++] << bits;
9576 hold += input[next++] << bits;
10663 //charf *buf; /* the input data */
11162 //charf *buf; /* input block */
11163 //ulg stored_len; /* length of input block */
11188 //charf *buf; /* input block, or NULL if too old */
11189 //ulg stored_len; /* length of input block */
11239 * Otherwise we can't have processed more than WSIZE input bytes since
11360 /* next input byte */
11361 this.input = null; // JS specific, because we have no pointers
11363 /* number of bytes available at input */
11365 /* total number of input bytes read so far */