Comparing version 0.0.22 to 0.0.23
{ | ||
"name": "arlib", | ||
"version": "0.0.22", | ||
"version": "0.0.23", | ||
"description": "Andras' Utility Functions", | ||
@@ -5,0 +5,0 @@ "license": "Apache-2.0", |
@@ -67,10 +67,11 @@ # arlib | ||
#### MongoId.parse( idString ) | ||
### MongoId.parse( idString ) | ||
return the mongoid string split into its component fields. | ||
For example, "5451a297f7e0f13c3a000001" parses to `{ timestamp: 1414636183, | ||
machineid: 16244977, pid: 15418, sequence: 1 }` | ||
MongoId.parse("5451a297f7e0f13c3a000001") | ||
// => { timestamp: 1414636183, machineid: 16244977, pid: 15418, sequence: 1 } | ||
Note that the timestamp field is a Unix timestamp (seconds since epoch), | ||
while getTimestamp() return a JavaScript timestamp (milliseconds since epoch). | ||
while getTimestamp() returns a JavaScript timestamp (milliseconds since epoch). | ||
@@ -77,0 +78,0 @@ ### phpdate( format, timestamp ) |
58566
150