forked from enviPath/enviPy
Current Dev State
This commit is contained in:
12
static/js/ketcher2/node_modules/crc32-stream/CHANGELOG.md
generated
vendored
Normal file
12
static/js/ketcher2/node_modules/crc32-stream/CHANGELOG.md
generated
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
## Changelog
|
||||
|
||||
**2.0.0** — <small>_February 13, 2017_</small> — [Diff](https://github.com/archiverjs/node-crc32-stream/compare/1.0.1...2.0.0)
|
||||
|
||||
- adopt nodejs core Hash API (GH #4)
|
||||
|
||||
**1.0.1** — <small>_January 12, 2016_</small> — [Diff](https://github.com/archiverjs/node-crc32-stream/compare/1.0.0...1.0.1)
|
||||
|
||||
- Switch to node-crc for performance (GH #3)
|
||||
- bump deps to ensure latest versions are used.
|
||||
|
||||
[Release Archive](https://github.com/archiverjs/node-crc32-stream/releases)
|
||||
22
static/js/ketcher2/node_modules/crc32-stream/LICENSE
generated
vendored
Normal file
22
static/js/ketcher2/node_modules/crc32-stream/LICENSE
generated
vendored
Normal file
@ -0,0 +1,22 @@
|
||||
Copyright (c) 2014 Chris Talkington, contributors.
|
||||
|
||||
Permission is hereby granted, free of charge, to any person
|
||||
obtaining a copy of this software and associated documentation
|
||||
files (the "Software"), to deal in the Software without
|
||||
restriction, including without limitation the rights to use,
|
||||
copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the
|
||||
Software is furnished to do so, subject to the following
|
||||
conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
||||
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
||||
OTHER DEALINGS IN THE SOFTWARE.
|
||||
79
static/js/ketcher2/node_modules/crc32-stream/README.md
generated
vendored
Normal file
79
static/js/ketcher2/node_modules/crc32-stream/README.md
generated
vendored
Normal file
@ -0,0 +1,79 @@
|
||||
# crc32-stream v2.0.0 [](https://travis-ci.org/archiverjs/node-crc32-stream) [](https://ci.appveyor.com/project/ctalkington/node-crc32-stream/branch/master)
|
||||
|
||||
crc32-stream is a streaming CRC32 checksumer. It uses [buffer-crc32](https://www.npmjs.org/package/buffer-crc32) behind the scenes to reliably handle binary data and fancy character sets. Data is passed through untouched.
|
||||
|
||||
### Install
|
||||
|
||||
```bash
|
||||
npm install crc32-stream --save
|
||||
```
|
||||
|
||||
You can also use `npm install https://github.com/archiverjs/node-crc32-stream/archive/master.tar.gz` to test upcoming versions.
|
||||
|
||||
### Usage
|
||||
|
||||
#### CRC32Stream
|
||||
|
||||
Inherits [Transform Stream](http://nodejs.org/api/stream.html#stream_class_stream_transform) options and methods.
|
||||
|
||||
```js
|
||||
var CRC32Stream = require('crc32-stream');
|
||||
|
||||
var source = fs.createReadStream('file.txt');
|
||||
var checksum = new CRC32Stream();
|
||||
|
||||
checksum.on('end', function(err) {
|
||||
// do something with checksum.digest() here
|
||||
});
|
||||
|
||||
// either pipe it
|
||||
source.pipe(checksum);
|
||||
|
||||
// or write it
|
||||
checksum.write('string');
|
||||
checksum.end();
|
||||
```
|
||||
|
||||
#### DeflateCRC32Stream
|
||||
|
||||
Inherits [zlib.DeflateRaw](http://nodejs.org/api/zlib.html#zlib_class_zlib_deflateraw) options and methods.
|
||||
|
||||
```js
|
||||
var DeflateCRC32Stream = require('crc32-stream').DeflateCRC32Stream;
|
||||
|
||||
var source = fs.createReadStream('file.txt');
|
||||
var checksum = new DeflateCRC32Stream();
|
||||
|
||||
checksum.on('end', function(err) {
|
||||
// do something with checksum.digest() here
|
||||
});
|
||||
|
||||
// either pipe it
|
||||
source.pipe(checksum);
|
||||
|
||||
// or write it
|
||||
checksum.write('string');
|
||||
checksum.end();
|
||||
```
|
||||
|
||||
### Instance API
|
||||
|
||||
#### digest()
|
||||
|
||||
Returns the checksum digest in unsigned form.
|
||||
|
||||
#### hex()
|
||||
|
||||
Returns the hexadecimal representation of the checksum digest. (ie E81722F0)
|
||||
|
||||
#### size(compressed)
|
||||
|
||||
Returns the raw size/length of passed-through data.
|
||||
|
||||
If `compressed` is `true`, it returns compressed length instead. (DeflateCRC32Stream)
|
||||
|
||||
## Things of Interest
|
||||
|
||||
- [Changelog](https://github.com/archiverjs/node-crc32-stream/releases)
|
||||
- [Contributing](https://github.com/archiverjs/node-crc32-stream/blob/master/CONTRIBUTING.md)
|
||||
- [MIT License](https://github.com/archiverjs/node-crc32-stream/blob/master/LICENSE-MIT)
|
||||
44
static/js/ketcher2/node_modules/crc32-stream/lib/crc32-stream.js
generated
vendored
Normal file
44
static/js/ketcher2/node_modules/crc32-stream/lib/crc32-stream.js
generated
vendored
Normal file
@ -0,0 +1,44 @@
|
||||
/**
|
||||
* node-crc32-stream
|
||||
*
|
||||
* Copyright (c) 2014 Chris Talkington, contributors.
|
||||
* Licensed under the MIT license.
|
||||
* https://github.com/archiverjs/node-crc32-stream/blob/master/LICENSE-MIT
|
||||
*/
|
||||
var inherits = require('util').inherits;
|
||||
var Transform = require('readable-stream').Transform;
|
||||
|
||||
var crc32 = require('crc').crc32;
|
||||
|
||||
var CRC32Stream = module.exports = function CRC32Stream(options) {
|
||||
Transform.call(this, options);
|
||||
this.checksum = new Buffer(4);
|
||||
this.checksum.writeInt32BE(0, 0);
|
||||
|
||||
this.rawSize = 0;
|
||||
};
|
||||
|
||||
inherits(CRC32Stream, Transform);
|
||||
|
||||
CRC32Stream.prototype._transform = function(chunk, encoding, callback) {
|
||||
if (chunk) {
|
||||
this.checksum = crc32(chunk, this.checksum);
|
||||
this.rawSize += chunk.length;
|
||||
}
|
||||
|
||||
callback(null, chunk);
|
||||
};
|
||||
|
||||
CRC32Stream.prototype.digest = function(encoding) {
|
||||
var checksum = new Buffer(4);
|
||||
checksum.writeUInt32BE(this.checksum >>> 0, 0);
|
||||
return encoding ? checksum.toString(encoding) : checksum;
|
||||
};
|
||||
|
||||
CRC32Stream.prototype.hex = function() {
|
||||
return this.digest('hex').toUpperCase();
|
||||
};
|
||||
|
||||
CRC32Stream.prototype.size = function() {
|
||||
return this.rawSize;
|
||||
};
|
||||
69
static/js/ketcher2/node_modules/crc32-stream/lib/deflate-crc32-stream.js
generated
vendored
Normal file
69
static/js/ketcher2/node_modules/crc32-stream/lib/deflate-crc32-stream.js
generated
vendored
Normal file
@ -0,0 +1,69 @@
|
||||
/**
|
||||
* node-crc32-stream
|
||||
*
|
||||
* Copyright (c) 2014 Chris Talkington, contributors.
|
||||
* Licensed under the MIT license.
|
||||
* https://github.com/archiverjs/node-crc32-stream/blob/master/LICENSE-MIT
|
||||
*/
|
||||
var zlib = require('zlib');
|
||||
var inherits = require('util').inherits;
|
||||
|
||||
var crc32 = require('crc').crc32;
|
||||
|
||||
var DeflateCRC32Stream = module.exports = function (options) {
|
||||
zlib.DeflateRaw.call(this, options);
|
||||
|
||||
this.checksum = new Buffer(4);
|
||||
this.checksum.writeInt32BE(0, 0);
|
||||
|
||||
this.rawSize = 0;
|
||||
this.compressedSize = 0;
|
||||
|
||||
// BC v0.8
|
||||
if (typeof zlib.DeflateRaw.prototype.push !== 'function') {
|
||||
this.on('data', function(chunk) {
|
||||
if (chunk) {
|
||||
this.compressedSize += chunk.length;
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
inherits(DeflateCRC32Stream, zlib.DeflateRaw);
|
||||
|
||||
DeflateCRC32Stream.prototype.push = function(chunk, encoding) {
|
||||
if (chunk) {
|
||||
this.compressedSize += chunk.length;
|
||||
}
|
||||
|
||||
return zlib.DeflateRaw.prototype.push.call(this, chunk, encoding);
|
||||
};
|
||||
|
||||
DeflateCRC32Stream.prototype.write = function(chunk, enc, cb) {
|
||||
if (chunk) {
|
||||
this.checksum = crc32(chunk, this.checksum);
|
||||
this.rawSize += chunk.length;
|
||||
}
|
||||
|
||||
return zlib.DeflateRaw.prototype.write.call(this, chunk, enc, cb);
|
||||
};
|
||||
|
||||
DeflateCRC32Stream.prototype.digest = function(encoding) {
|
||||
var checksum = new Buffer(4);
|
||||
checksum.writeUInt32BE(this.checksum >>> 0, 0);
|
||||
return encoding ? checksum.toString(encoding) : checksum;
|
||||
};
|
||||
|
||||
DeflateCRC32Stream.prototype.hex = function() {
|
||||
return this.digest('hex').toUpperCase();
|
||||
};
|
||||
|
||||
DeflateCRC32Stream.prototype.size = function(compressed) {
|
||||
compressed = compressed || false;
|
||||
|
||||
if (compressed) {
|
||||
return this.compressedSize;
|
||||
} else {
|
||||
return this.rawSize;
|
||||
}
|
||||
};
|
||||
10
static/js/ketcher2/node_modules/crc32-stream/lib/index.js
generated
vendored
Normal file
10
static/js/ketcher2/node_modules/crc32-stream/lib/index.js
generated
vendored
Normal file
@ -0,0 +1,10 @@
|
||||
/**
|
||||
* node-crc32-stream
|
||||
*
|
||||
* Copyright (c) 2014 Chris Talkington, contributors.
|
||||
* Licensed under the MIT license.
|
||||
* https://github.com/archiverjs/node-crc32-stream/blob/master/LICENSE-MIT
|
||||
*/
|
||||
exports = module.exports = require('./crc32-stream');
|
||||
exports.CRC32Stream = exports;
|
||||
exports.DeflateCRC32Stream = require('./deflate-crc32-stream');
|
||||
70
static/js/ketcher2/node_modules/crc32-stream/package.json
generated
vendored
Normal file
70
static/js/ketcher2/node_modules/crc32-stream/package.json
generated
vendored
Normal file
@ -0,0 +1,70 @@
|
||||
{
|
||||
"_from": "crc32-stream@^2.0.0",
|
||||
"_id": "crc32-stream@2.0.0",
|
||||
"_inBundle": false,
|
||||
"_integrity": "sha1-483TtN8xaN10494/u8t7KX/pCPQ=",
|
||||
"_location": "/crc32-stream",
|
||||
"_phantomChildren": {},
|
||||
"_requested": {
|
||||
"type": "range",
|
||||
"registry": true,
|
||||
"raw": "crc32-stream@^2.0.0",
|
||||
"name": "crc32-stream",
|
||||
"escapedName": "crc32-stream",
|
||||
"rawSpec": "^2.0.0",
|
||||
"saveSpec": null,
|
||||
"fetchSpec": "^2.0.0"
|
||||
},
|
||||
"_requiredBy": [
|
||||
"/compress-commons"
|
||||
],
|
||||
"_resolved": "https://registry.npmjs.org/crc32-stream/-/crc32-stream-2.0.0.tgz",
|
||||
"_shasum": "e3cdd3b4df3168dd74e3de3fbbcb7b297fe908f4",
|
||||
"_spec": "crc32-stream@^2.0.0",
|
||||
"_where": "/home/manfred/enviPath/ketcher2/ketcher/node_modules/compress-commons",
|
||||
"author": {
|
||||
"name": "Chris Talkington",
|
||||
"url": "http://christalkington.com/"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/archiverjs/node-crc32-stream/issues"
|
||||
},
|
||||
"bundleDependencies": false,
|
||||
"dependencies": {
|
||||
"crc": "^3.4.4",
|
||||
"readable-stream": "^2.0.0"
|
||||
},
|
||||
"deprecated": false,
|
||||
"description": "a streaming CRC32 checksumer",
|
||||
"devDependencies": {
|
||||
"chai": "^3.4.0",
|
||||
"mocha": "^3.2.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">= 0.10.0"
|
||||
},
|
||||
"files": [
|
||||
"lib"
|
||||
],
|
||||
"homepage": "https://github.com/archiverjs/node-crc32-stream",
|
||||
"keywords": [
|
||||
"crc32-stream",
|
||||
"crc32",
|
||||
"stream",
|
||||
"checksum"
|
||||
],
|
||||
"license": "MIT",
|
||||
"main": "lib/index.js",
|
||||
"name": "crc32-stream",
|
||||
"publishConfig": {
|
||||
"registry": "https://registry.npmjs.org/"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/archiverjs/node-crc32-stream.git"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "mocha --reporter dot"
|
||||
},
|
||||
"version": "2.0.0"
|
||||
}
|
||||
Reference in New Issue
Block a user