92 lines
4.5 KiB
JSON
92 lines
4.5 KiB
JSON
{
|
|
"_args": [
|
|
[
|
|
{
|
|
"raw": "uuid-js@^0.7.5",
|
|
"scope": null,
|
|
"escapedName": "uuid-js",
|
|
"name": "uuid-js",
|
|
"rawSpec": "^0.7.5",
|
|
"spec": ">=0.7.5 <0.8.0",
|
|
"type": "range"
|
|
},
|
|
"/Volumes/2009-SSD/GT2/GT2-iOS/node_modules/expo"
|
|
]
|
|
],
|
|
"_from": "uuid-js@>=0.7.5 <0.8.0",
|
|
"_id": "uuid-js@0.7.5",
|
|
"_inCache": true,
|
|
"_location": "/uuid-js",
|
|
"_npmUser": {
|
|
"name": "patricknegri",
|
|
"email": "patrick@iugu.com.br"
|
|
},
|
|
"_npmVersion": "1.3.14",
|
|
"_phantomChildren": {},
|
|
"_requested": {
|
|
"raw": "uuid-js@^0.7.5",
|
|
"scope": null,
|
|
"escapedName": "uuid-js",
|
|
"name": "uuid-js",
|
|
"rawSpec": "^0.7.5",
|
|
"spec": ">=0.7.5 <0.8.0",
|
|
"type": "range"
|
|
},
|
|
"_requiredBy": [
|
|
"/expo"
|
|
],
|
|
"_resolved": "https://registry.npmjs.org/uuid-js/-/uuid-js-0.7.5.tgz",
|
|
"_shasum": "6c886d02a53d2d40dcf25d91a170b4a7b25b94d0",
|
|
"_shrinkwrap": null,
|
|
"_spec": "uuid-js@^0.7.5",
|
|
"_where": "/Volumes/2009-SSD/GT2/GT2-iOS/node_modules/expo",
|
|
"author": {
|
|
"name": "Patrick Negri",
|
|
"email": "patrick@iugu.com.br"
|
|
},
|
|
"bugs": {
|
|
"url": "https://github.com/pnegri/uuid-js/issues"
|
|
},
|
|
"contributors": [
|
|
{
|
|
"name": "Christoph Tavan"
|
|
},
|
|
{
|
|
"name": "Gary Dusbabek",
|
|
"email": "gdusbabek@gmail.com"
|
|
}
|
|
],
|
|
"dependencies": {},
|
|
"description": "A js library to generate and parse UUIDs,TimeUUIDs and generate TimeUUID based on Date for range selections",
|
|
"devDependencies": {
|
|
"sinon": "1.2.0"
|
|
},
|
|
"directories": {
|
|
"lib": "./lib"
|
|
},
|
|
"dist": {
|
|
"shasum": "6c886d02a53d2d40dcf25d91a170b4a7b25b94d0",
|
|
"tarball": "https://registry.npmjs.org/uuid-js/-/uuid-js-0.7.5.tgz"
|
|
},
|
|
"engines": {
|
|
"node": ">= 0.4.0"
|
|
},
|
|
"homepage": "http://github.com/pnegri/uuid-js",
|
|
"main": "./lib/uuid.js",
|
|
"maintainers": [
|
|
{
|
|
"name": "patricknegri",
|
|
"email": "patrick@iugu.com.br"
|
|
}
|
|
],
|
|
"name": "uuid-js",
|
|
"optionalDependencies": {},
|
|
"readme": "# UUID-js\n\nA js library to generate and parse UUID's, TimeUUID's and generate empty TimeUUID's based on TimeStamp for range selections.\n\n```javascript\nvar UUID = require('uuid-js');\n\n\n// Generate a V4 UUID\nvar uuid4 = UUID.create();\nconsole.log(uuid4.toString());\n// Prints: 896b677f-fb14-11e0-b14d-d11ca798dbac\n\n\n// Generate a V1 TimeUUID\nvar uuid1 = UUID.create(1);\nconsole.log(uuid1.toString());\n\n\n// First and last possible v1 TimeUUID for a given timestamp:\nvar date = new Date().getTime();\nvar uuidFirst = UUID.fromTime(date, false);\nvar uuidLast = UUID.fromTime(date, true);\nconsole.log(uuidFirst.toString(), uuidLast.toString());\n// Prints: aa0f9af0-0e1f-11e1-0000-000000000000 aa0f9af0-0e1f-11e1-c0ff-ffffffffffff\n\n\n// Use these TimeUUID's to perform range queries in cassandra:\nvar today = new Date().getTime();\nvar last30days = (new Date().setDate( today.getDate() - 30 )).getTime();\n\nvar rangeStart = UUID.firstFromTime(last30days);\nvar rangeEnd = UUID.lastFromTime(today);\n\nvar query = ...(\"select first 50 reversed ?..? from user_twits where key=?\", [ rangeStart, rangeEnd, \"patricknegri\" ]);\n```\n\n\n## Instalation\n\n```\n$ npm install uuid-js\n```\n\n## Functions List\n\nThese are available just with require and return an instance of the UUID object:\n\n```javascript\nUUID.create(4); // Generate V4 UUID\n\nUUID.create(1); // Generate V1 TimeUUID\n\nUUID.fromTime(time, last); // Generate a V1 empty TimeUUID from a Date object (Ex: new Date().getTime() )\n\nUUID.firstFromTime(time); // Same as fromTime but first sequence\n\nUUID.lastFromTime(time); // Same as fromTime but last sequence\n\nUUID.fromURN(strId); // Generate a UUID object from string\n\nUUID.fromBytes(ints); // Generate a UUID object from bytes\n\nUUID.fromBinary(binary); // Generate a UUID object from binary\n```\n\n## Methods List\n\nThese must be called on an instance of the UUID object:\n\n```javascript\nuuid.fromParts(timeLow, timeMid, timeHiAndVersion, clockSeqHiAndReserved, clockSeqLow, node);\n\nuuid.toString(); // hex string version of UUID\n\nuuid.toURN(); // same as hex, but with urn:uuid prefix\n\nuuid.toBytes(); // converted to an array of bytes\n```\n\n## Tests\n\n```\nmake test\n```\n\n## Contributors\n\n * Christoph Tavan <dev@tavan.de>\n\nThis work was based RFC and by the work of these people.\n\n * LiosK <contact@mail.liosk.net>\n * Gary Dusbabek <gdusbabek@gmail.com>\n",
|
|
"readmeFilename": "README.md",
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "git://github.com/pnegri/uuid-js.git"
|
|
},
|
|
"version": "0.7.5"
|
|
}
|