Skip to content
Browse files

updated modules

  • Loading branch information...
1 parent bd56e2a commit 8e3d3e3cc075cd45cf38cb77a2fd97973ef7b284 @gagle committed
View
25 test/tests/node_modules/buffered-writer/README.md
@@ -5,14 +5,33 @@ Node BufferedWriter
#### Fully configurable buffered writer for node.js ####
-[Availability](#availability) | [Compatibility](#compatibility) | [Documentation](#documentation)
+[Show me!](#showme) | [Availability](#availability) | [Compatibility](#compatibility) | [Documentation](#documentation)
-Version: 0.1.10
+Version: 0.1.11
When you need to write a file you typically write the content in little chunks at a time. To avoid multiple calls to the underlying I/O layer you need to use a piece of memory called "buffer", so instead of writting directly to the disk, you write to the buffer and when it is filled the content is written to disk. Doing this you win performance.
This library allows you to write files using internal buffers, so you don't have to worry about them.
+<a name="showme"></a>
+#### Show me! [](#start) ####
+
+```javascript
+var BufferedWriter = require ("buffered-writer");
+
+new BufferedWriter ("file")
+ .on ("error", function (error){
+ console.log (error);
+ })
+
+ .write ([0x00, 0x01, 0x02], 0, 3) //Writes 0x00, 0x01, 0x02
+ .write (new Buffer ([0x03, 0x04]), 1, 1) //Writes 0x04
+ .write (0x0506) //Writes 0x05, 0x06
+ .close ();
+```
+
+***
+
<a name="availability"></a>
#### Availability [](#start) ####
@@ -22,8 +41,6 @@ Via npm:
npm install buffered-writer
```
-Or simply copying `build/buffered-writer.js` into your project's directory and `require()` accordingly.
-
***
<a name="compatibility"></a>
View
2 test/tests/node_modules/buffered-writer/buffered-writer.js
@@ -1 +1 @@
-"use strict";var EVENTS=require("events"),FS=require("fs"),Error=require("errno-codes");Error.create("INVALID_BUFFER_SIZE",Error.getNextAvailableErrorCode(),"The buffer size must be greater than 0.");var BUFFER_SIZE=16384,EOL=process.platform.indexOf("win")!==-1?new Buffer([13,10]):new Buffer([10]),toHexArray=function(e){var t=[];do t.unshift(e&255),e>>>=8;while(e);return t},BufferedWriter=function(e,t){EVENTS.EventEmitter.call(this),t=t||{},t.bufferSize===0&&(t.bufferSize=-1),this._settings={bufferSize:t.bufferSize||BUFFER_SIZE,encoding:t.encoding||null,append:t.append?"a":"w"};if(this._settings.bufferSize<1)throw Error.get(Error.INVALID_BUFFER_SIZE);this._fileName=e,this._stream=null,this._buffer=null,this._bufferOffset=0};BufferedWriter.prototype=Object.create(EVENTS.EventEmitter.prototype),BufferedWriter.prototype.constructor=BufferedWriter,BufferedWriter.prototype._canWrite=function(e){return e+this._bufferOffset>this._settings.bufferSize&&(e=this._settings.bufferSize-this._bufferOffset),e},BufferedWriter.prototype._flush=function(){this._stream.write(new Buffer(this._bufferOffset!==this._settings.bufferSize?this._buffer.slice(0,this._bufferOffset):this._buffer)),this._bufferOffset=0},BufferedWriter.prototype._write=function(e,t,n){var r=this;this._buffer||(this._buffer=new Buffer(this._settings.bufferSize)),this.touch(r._settings.append);if(n===0)return;var i=this._canWrite(n);e.copy(this._buffer,this._bufferOffset,t,t+i),this._bufferOffset+=i,t+=i,n-=i,this._bufferOffset===this._settings.bufferSize&&(this._flush(),n!==0&&this._write(e,t,n))},BufferedWriter.prototype.close=function(e){if(!this._stream)return;this._bufferOffset!==0&&this._flush();var t=this;this._stream.on("close",function(){e&&e.call(this)}),this._stream.destroySoon(),this._stream=null,this._fd=null,this._buffer=null},BufferedWriter.prototype.newLine=function(){return this._write(EOL,0,EOL.length),this},BufferedWriter.prototype.touch=function(e){if(this._stream)return this;e=e||"w";var t=this;return this._stream=FS.createWriteStream(this._fileName,{flags:e,encoding:t._settings.encoding}).on("error",function(e){t.emit("error",e)}),this},BufferedWriter.prototype.write=function(e,t,n){var r=typeof e;if(r==="number")t=0,e=toHexArray(e),n=e.length,e=new Buffer(e);else if(r==="string")t=0,n=Buffer.byteLength(e,this._settings.encoding),e=new Buffer(e,this._settings.encoding);else{Array.isArray(e)&&(e=new Buffer(e));var i=arguments.length;i===1&&(t=0,n=e.length==0?0:1)}return this._write(e,t,n),this},module.exports=BufferedWriter;
+"use strict";var EVENTS=require("events"),FS=require("fs"),Error=require("errno-codes");Error.create(Error.getNextAvailableErrno(),"INVALID_BUFFER_SIZE","The buffer size must be greater than 0.");var BUFFER_SIZE=16384,EOL=process.platform.indexOf("win")!==-1?new Buffer([13,10]):new Buffer([10]),toHexArray=function(e){var t=[];do t.unshift(e&255),e>>>=8;while(e);return t},BufferedWriter=function(e,t){EVENTS.EventEmitter.call(this),t=t||{},t.bufferSize===0&&(t.bufferSize=-1),this._settings={bufferSize:t.bufferSize||BUFFER_SIZE,encoding:t.encoding||null,append:t.append?"a":"w"};if(this._settings.bufferSize<1)throw Error.get(Error.INVALID_BUFFER_SIZE);this._fileName=e,this._stream=null,this._buffer=null,this._bufferOffset=0};BufferedWriter.prototype=Object.create(EVENTS.EventEmitter.prototype),BufferedWriter.prototype.constructor=BufferedWriter,BufferedWriter.prototype._canWrite=function(e){return e+this._bufferOffset>this._settings.bufferSize&&(e=this._settings.bufferSize-this._bufferOffset),e},BufferedWriter.prototype._flush=function(){this._stream.write(new Buffer(this._bufferOffset!==this._settings.bufferSize?this._buffer.slice(0,this._bufferOffset):this._buffer)),this._bufferOffset=0},BufferedWriter.prototype._write=function(e,t,n){var r=this;this._buffer||(this._buffer=new Buffer(this._settings.bufferSize)),this.touch(r._settings.append);if(n===0)return;var i=this._canWrite(n);e.copy(this._buffer,this._bufferOffset,t,t+i),this._bufferOffset+=i,t+=i,n-=i,this._bufferOffset===this._settings.bufferSize&&(this._flush(),n!==0&&this._write(e,t,n))},BufferedWriter.prototype.close=function(e){if(!this._stream)return;this._bufferOffset!==0&&this._flush();var t=this;this._stream.on("close",function(){e&&e.call(this)}),this._stream.destroySoon(),this._stream=null,this._fd=null,this._buffer=null},BufferedWriter.prototype.newLine=function(){return this._write(EOL,0,EOL.length),this},BufferedWriter.prototype.touch=function(e){if(this._stream)return this;e=e||"w";var t=this;return this._stream=FS.createWriteStream(this._fileName,{flags:e,encoding:t._settings.encoding}).on("error",function(e){t.emit("error",e)}),this},BufferedWriter.prototype.write=function(e,t,n){var r=typeof e;if(r==="number")t=0,e=toHexArray(e),n=e.length,e=new Buffer(e);else if(r==="string")t=0,n=Buffer.byteLength(e,this._settings.encoding),e=new Buffer(e,this._settings.encoding);else{Array.isArray(e)&&(e=new Buffer(e));var i=arguments.length;i===1&&(t=0,n=e.length==0?0:1)}return this._write(e,t,n),this},module.exports=BufferedWriter;
View
4 test/tests/node_modules/buffered-writer/node_modules/errno-codes/README.md
@@ -7,7 +7,7 @@ Node Error
[Show me!](#showme) | [Availability](#availability) | [Compatibility](#compatibility) | [Documentation](#documentation)
-Version: 1.0.0
+Version: 1.0.1
When you are writing a node.js module you'll probably deal with errors. If you get a predefined error you can just resend it but if you want to instantiate a predefined one you need an errno code. Node.js does not expose these errors. Furthermore, they're not the standard errno codes. They are defined at [`deps/uv/include/uv.h`](https://github.com/joyent/node/blob/master/deps/uv/include/uv.h).
@@ -33,6 +33,8 @@ Prints:
*/
```
+***
+
<a name="availability"></a>
#### Availability [](#start) ####
View
2 test/tests/node_modules/buffered-writer/node_modules/errno-codes/error.js
@@ -1 +1 @@
-"use strict";var errors={UNKNOWN:{errno:"UNKNOWN",code:-1,description:"unknown error"},OK:{errno:"OK",code:0,description:"success"},EOF:{errno:"EOF",code:1,description:"end of file"},EADDRINFO:{errno:"EADDRINFO",code:2,description:"getaddrinfo error"},EACCES:{errno:"EACCES",code:3,description:"permission denied"},EAGAIN:{errno:"EAGAIN",code:4,description:"no more processes"},EADDRINUSE:{errno:"EADDRINUSE",code:5,description:"address already in use"},EADDRNOTAVAIL:{errno:"EADDRNOTAVAIL",code:6,description:""},EAFNOSUPPORT:{errno:"EAFNOSUPPORT",code:7,description:""},EALREADY:{errno:"EALREADY",code:8,description:""},EBADF:{errno:"EBADF",code:9,description:"bad file descriptor"},EBUSY:{errno:"EBUSY",code:10,description:"resource busy or locked"},ECONNABORTED:{errno:"ECONNABORTED",code:11,description:"software caused connection abort"},ECONNREFUSED:{errno:"ECONNREFUSED",code:12,description:"connection refused"},ECONNRESET:{errno:"ECONNRESET",code:13,description:"connection reset by peer"},EDESTADDRREQ:{errno:"EDESTADDRREQ",code:14,description:"destination address required"},EFAULT:{errno:"EFAULT",code:15,description:"bad address in system call argument"},EHOSTUNREACH:{errno:"EHOSTUNREACH",code:16,description:"host is unreachable"},EINTR:{errno:"EINTR",code:17,description:"interrupted system call"},EINVAL:{errno:"EINVAL",code:18,description:"invalid argument"},EISCONN:{errno:"EISCONN",code:19,description:"socket is already connected"},EMFILE:{errno:"EMFILE",code:20,description:"too many open files"},EMSGSIZE:{errno:"EMSGSIZE",code:21,description:"message too long"},ENETDOWN:{errno:"ENETDOWN",code:22,description:"network is down"},ENETUNREACH:{errno:"ENETUNREACH",code:23,description:"network is unreachable"},ENFILE:{errno:"ENFILE",code:24,description:"file table overflow"},ENOBUFS:{errno:"ENOBUFS",code:25,description:"no buffer space available"},ENOMEM:{errno:"ENOMEM",code:26,description:"not enough memory"},ENOTDIR:{errno:"ENOTDIR",code:27,description:"not a directory"},EISDIR:{errno:"EISDIR",code:28,description:"illegal operation on a directory"},ENONET:{errno:"ENONET",code:29,description:"machine is not on the network"},ENOTCONN:{errno:"ENOTCONN",code:31,description:"socket is not connected"},ENOTSOCK:{errno:"ENOTSOCK",code:32,description:"socket operation on non-socket"},ENOTSUP:{errno:"ENOTSUP",code:33,description:"operation not supported on socket"},ENOENT:{errno:"ENOENT",code:34,description:"no such file or directory"},ENOSYS:{errno:"ENOSYS",code:35,description:"function not implemented"},EPIPE:{errno:"EPIPE",code:36,description:"broken pipe"},EPROTO:{errno:"EPROTO",code:37,description:"protocol error"},EPROTONOSUPPORT:{errno:"EPROTONOSUPPORT",code:38,description:"protocol not supported"},EPROTOTYPE:{errno:"EPROTOTYPE",code:39,description:"protocol wrong type for socket"},ETIMEDOUT:{errno:"ETIMEDOUT",code:40,description:"connection timed out"},ECHARSET:{errno:"ECHARSET",code:41,description:""},EAIFAMNOSUPPORT:{errno:"EAIFAMNOSUPPORT",code:42,description:""},EAISERVICE:{errno:"EAISERVICE",code:44,description:""},EAISOCKTYPE:{errno:"EAISOCKTYPE",code:45,description:""},ESHUTDOWN:{errno:"ESHUTDOWN",code:46,description:""},EEXIST:{errno:"EEXIST",code:47,description:"file already exists"},ESRCH:{errno:"ESRCH",code:48,description:"no such process"},ENAMETOOLONG:{errno:"ENAMETOOLONG",code:49,description:"name too long"},EPERM:{errno:"EPERM",code:50,description:"operation not permitted"},ELOOP:{errno:"ELOOP",code:51,description:"too many symbolic links encountered"},EXDEV:{errno:"EXDEV",code:52,description:"cross-device link not permitted"},ENOTEMPTY:{errno:"ENOTEMPTY",code:53,description:"directory not empty"},ENOSPC:{errno:"ENOSPC",code:54,description:"no space left on device"},EIO:{errno:"EIO",code:55,description:"i/o error"},EROFS:{errno:"EROFS",code:56,description:"read-only file system"},ENODEV:{errno:"ENODEV",code:57,description:"no such device"}},codes={"-1":"UNKNOWN",0:"OK",1:"EOF",2:"EADDRINFO",3:"EACCES",4:"EAGAIN",5:"EADDRINUSE",6:"EADDRNOTAVAIL",7:"EAFNOSUPPORT",8:"EALREADY",9:"EBADF",10:"EBUSY",11:"ECONNABORTED",12:"ECONNREFUSED",13:"ECONNRESET",14:"EDESTADDRREQ",15:"EFAULT",16:"EHOSTUNREACH",17:"EINTR",18:"EINVAL",19:"EISCONN",20:"EMFILE",21:"EMSGSIZE",22:"ENETDOWN",23:"ENETUNREACH",24:"ENFILE",25:"ENOBUFS",26:"ENOMEM",27:"ENOTDIR",28:"EISDIR",29:"ENONET",31:"ENOTCONN",32:"ENOTSOCK",33:"ENOTSUP",34:"ENOENT",35:"ENOSYS",36:"EPIPE",37:"EPROTO",38:"EPROTONOSUPPORT",39:"EPROTOTYPE",40:"ETIMEDOUT",41:"ECHARSET",42:"EAIFAMNOSUPPORT",44:"EAISERVICE",45:"EAISOCKTYPE",46:"ESHUTDOWN",47:"EEXIST",48:"ESRCH",49:"ENAMETOOLONG",50:"EPERM",51:"ELOOP",52:"EXDEV",53:"ENOTEMPTY",54:"ENOSPC",55:"EIO",56:"EROFS",57:"ENODEV"},nextAvailableErrorCode=100;errors.create=function(e,t,n){var r={errno:e,code:t,description:n};errors[e]=r,codes[t]=e},errors.get=function(e,t){var n,r=typeof e;r==="number"?n=errors[codes[e]]:r==="string"?n=errors[e]:n=e;var i=new Error(n.errno);i.errno=n.errno,i.code=n.code;var s=n.description;if(t)for(var o in t)s=s.replace(new RegExp("\\{"+o+"\\}","g"),t[o]);return i.description=s,i},errors.getNextAvailableErrorCode=function(){var e=nextAvailableErrorCode;return nextAvailableErrorCode++,e},module.exports=errors;
+"use strict";var errors={UNKNOWN:{errno:-1,code:"UNKNOWN",description:"unknown error"},OK:{errno:0,code:"OK",description:"success"},EOF:{errno:1,code:"EOF",description:"end of file"},EADDRINFO:{errno:2,code:"EADDRINFO",description:"getaddrinfo error"},EACCES:{errno:3,code:"EACCES",description:"permission denied"},EAGAIN:{errno:4,code:"EAGAIN",description:"no more processes"},EADDRINUSE:{errno:5,code:"EADDRINUSE",description:"address already in use"},EADDRNOTAVAIL:{errno:6,code:"EADDRNOTAVAIL",description:""},EAFNOSUPPORT:{errno:7,code:"EAFNOSUPPORT",description:""},EALREADY:{errno:8,code:"EALREADY",description:""},EBADF:{errno:9,code:"EBADF",description:"bad file descriptor"},EBUSY:{errno:10,code:"EBUSY",description:"resource busy or locked"},ECONNABORTED:{errno:11,code:"ECONNABORTED",description:"software caused connection abort"},ECONNREFUSED:{errno:12,code:"ECONNREFUSED",description:"connection refused"},ECONNRESET:{errno:13,code:"ECONNRESET",description:"connection reset by peer"},EDESTADDRREQ:{errno:14,code:"EDESTADDRREQ",description:"destination address required"},EFAULT:{errno:15,code:"EFAULT",description:"bad address in system call argument"},EHOSTUNREACH:{errno:16,code:"EHOSTUNREACH",description:"host is unreachable"},EINTR:{errno:17,code:"EINTR",description:"interrupted system call"},EINVAL:{errno:18,code:"EINVAL",description:"invalid argument"},EISCONN:{errno:19,code:"EISCONN",description:"socket is already connected"},EMFILE:{errno:20,code:"EMFILE",description:"too many open files"},EMSGSIZE:{errno:21,code:"EMSGSIZE",description:"message too long"},ENETDOWN:{errno:22,code:"ENETDOWN",description:"network is down"},ENETUNREACH:{errno:23,code:"ENETUNREACH",description:"network is unreachable"},ENFILE:{errno:24,code:"ENFILE",description:"file table overflow"},ENOBUFS:{errno:25,code:"ENOBUFS",description:"no buffer space available"},ENOMEM:{errno:26,code:"ENOMEM",description:"not enough memory"},ENOTDIR:{errno:27,code:"ENOTDIR",description:"not a directory"},EISDIR:{errno:28,code:"EISDIR",description:"illegal operation on a directory"},ENONET:{errno:29,code:"ENONET",description:"machine is not on the network"},ENOTCONN:{errno:31,code:"ENOTCONN",description:"socket is not connected"},ENOTSOCK:{errno:32,code:"ENOTSOCK",description:"socket operation on non-socket"},ENOTSUP:{errno:33,code:"ENOTSUP",description:"operation not supported on socket"},ENOENT:{errno:34,code:"ENOENT",description:"no such file or directory"},ENOSYS:{errno:35,code:"ENOSYS",description:"function not implemented"},EPIPE:{errno:36,code:"EPIPE",description:"broken pipe"},EPROTO:{errno:37,code:"EPROTO",description:"protocol error"},EPROTONOSUPPORT:{errno:38,code:"EPROTONOSUPPORT",description:"protocol not supported"},EPROTOTYPE:{errno:39,code:"EPROTOTYPE",description:"protocol wrong type for socket"},ETIMEDOUT:{errno:40,code:"ETIMEDOUT",description:"connection timed out"},ECHARSET:{errno:41,code:"ECHARSET",description:""},EAIFAMNOSUPPORT:{errno:42,code:"EAIFAMNOSUPPORT",description:""},EAISERVICE:{errno:44,code:"EAISERVICE",description:""},EAISOCKTYPE:{errno:45,code:"EAISOCKTYPE",description:""},ESHUTDOWN:{errno:46,code:"ESHUTDOWN",description:""},EEXIST:{errno:47,code:"EEXIST",description:"file already exists"},ESRCH:{errno:48,code:"ESRCH",description:"no such process"},ENAMETOOLONG:{errno:49,code:"ENAMETOOLONG",description:"name too long"},EPERM:{errno:50,code:"EPERM",description:"operation not permitted"},ELOOP:{errno:51,code:"ELOOP",description:"too many symbolic links encountered"},EXDEV:{errno:52,code:"EXDEV",description:"cross-device link not permitted"},ENOTEMPTY:{errno:53,code:"ENOTEMPTY",description:"directory not empty"},ENOSPC:{errno:54,code:"ENOSPC",description:"no space left on device"},EIO:{errno:55,code:"EIO",description:"i/o error"},EROFS:{errno:56,code:"EROFS",description:"read-only file system"},ENODEV:{errno:57,code:"ENODEV",description:"no such device"}},codes={"-1":"UNKNOWN",0:"OK",1:"EOF",2:"EADDRINFO",3:"EACCES",4:"EAGAIN",5:"EADDRINUSE",6:"EADDRNOTAVAIL",7:"EAFNOSUPPORT",8:"EALREADY",9:"EBADF",10:"EBUSY",11:"ECONNABORTED",12:"ECONNREFUSED",13:"ECONNRESET",14:"EDESTADDRREQ",15:"EFAULT",16:"EHOSTUNREACH",17:"EINTR",18:"EINVAL",19:"EISCONN",20:"EMFILE",21:"EMSGSIZE",22:"ENETDOWN",23:"ENETUNREACH",24:"ENFILE",25:"ENOBUFS",26:"ENOMEM",27:"ENOTDIR",28:"EISDIR",29:"ENONET",31:"ENOTCONN",32:"ENOTSOCK",33:"ENOTSUP",34:"ENOENT",35:"ENOSYS",36:"EPIPE",37:"EPROTO",38:"EPROTONOSUPPORT",39:"EPROTOTYPE",40:"ETIMEDOUT",41:"ECHARSET",42:"EAIFAMNOSUPPORT",44:"EAISERVICE",45:"EAISOCKTYPE",46:"ESHUTDOWN",47:"EEXIST",48:"ESRCH",49:"ENAMETOOLONG",50:"EPERM",51:"ELOOP",52:"EXDEV",53:"ENOTEMPTY",54:"ENOSPC",55:"EIO",56:"EROFS",57:"ENODEV"},nextAvailableErrno=100;errors.create=function(e,t,n){var r={errno:e,code:t,description:n};errors[t]=r,codes[e]=t},errors.get=function(e,t){var n,r=typeof e;r==="number"?n=errors[codes[e]]:r==="string"?n=errors[e]:n=e;var i=new Error(n.code);i.errno=n.errno,i.code=n.code;var s=n.description;if(t)for(var o in t)s=s.replace(new RegExp("\\{"+o+"\\}","g"),t[o]);return i.description=s,i},errors.getNextAvailableErrno=function(){var e=nextAvailableErrno;return nextAvailableErrno++,e},module.exports=errors;
View
9 test/tests/node_modules/buffered-writer/node_modules/errno-codes/package.json
@@ -1,6 +1,6 @@
{
"name": "errno-codes",
- "version": "1.0.0",
+ "version": "1.0.1",
"description": "Exposes the errno codes for node.js.",
"keywords": [
"error",
@@ -23,7 +23,10 @@
}
],
"main": "error",
- "readme": "<a name=\"start\"></a>\r\n\r\nNode Error\r\n==========\r\n\r\n#### Exposes the errno codes for node.js. ####\r\n\r\n[Show me!](#showme) | [Availability](#availability) | [Compatibility](#compatibility) | [Documentation](#documentation)\r\n\r\nVersion: 1.0.0\r\n\r\nWhen you are writing a node.js module you'll probably deal with errors. If you get a predefined error you can just resend it but if you want to instantiate a predefined one you need an errno code. Node.js does not expose these errors. Furthermore, they're not the standard errno codes. They are defined at [`deps/uv/include/uv.h`](https://github.com/joyent/node/blob/master/deps/uv/include/uv.h).\r\n\r\nThis module eases the error management providing predefined `Error` instances for every errno code and the ability to create customized errors.\r\n\r\n<a name=\"showme\"></a>\r\n#### Show me! [↑](#start) ####\r\n\r\n```javascript\r\nvar Error = require (\"error\");\r\n\r\nconsole.log (Error.get (Error.ENOENT));\r\n\r\n/*\r\nPrints:\r\n\r\n{\r\n\t[Error: ENOENT]\r\n\terrno: 34,\r\n\tcode: \"ENOENT\",\r\n\tdescription: \"no such file or directory\"\r\n}\r\n*/\r\n```\r\n\r\n<a name=\"availability\"></a>\r\n#### Availability [↑](#start) ####\r\n\r\nVia npm:\r\n\r\n```\r\nnpm install errno-codes\r\n```\r\n\r\nOr simply copying `build/error.js` into your project's directory and `require()` accordingly.\r\n\r\n***\r\n\r\n<a name=\"compatibility\"></a>\r\n#### Compatibility [↑](#start) ####\r\n\r\n✔ Node *\r\n\r\n***\r\n\r\n<a name=\"documentation\"></a>\r\n#### Documentation [↑](#start) ####\r\n \r\n[Reference](https://github.com/Gagle/Node-Error/wiki/Reference) \r\n[Examples](https://github.com/Gagle/Node-Error/tree/master/examples) \r\n[Change Log](https://github.com/Gagle/Node-Error/wiki/Change-Log) \r\n[MIT License](https://github.com/Gagle/Node-Error/blob/master/LICENSE)",
- "_id": "errno-codes@1.0.0",
+ "readme": "<a name=\"start\"></a>\r\n\r\nNode Error\r\n==========\r\n\r\n#### Exposes the errno codes for node.js. ####\r\n\r\n[Show me!](#showme) | [Availability](#availability) | [Compatibility](#compatibility) | [Documentation](#documentation)\r\n\r\nVersion: 1.0.1\r\n\r\nWhen you are writing a node.js module you'll probably deal with errors. If you get a predefined error you can just resend it but if you want to instantiate a predefined one you need an errno code. Node.js does not expose these errors. Furthermore, they're not the standard errno codes. They are defined at [`deps/uv/include/uv.h`](https://github.com/joyent/node/blob/master/deps/uv/include/uv.h).\r\n\r\nThis module eases the error management providing predefined `Error` instances for every errno code and the ability to create customized errors.\r\n\r\n<a name=\"showme\"></a>\r\n#### Show me! [↑](#start) ####\r\n\r\n```javascript\r\nvar Error = require (\"error\");\r\n\r\nconsole.log (Error.get (Error.ENOENT));\r\n\r\n/*\r\nPrints:\r\n\r\n{\r\n\t[Error: ENOENT]\r\n\terrno: 34,\r\n\tcode: \"ENOENT\",\r\n\tdescription: \"no such file or directory\"\r\n}\r\n*/\r\n```\r\n\r\n***\r\n\r\n<a name=\"availability\"></a>\r\n#### Availability [↑](#start) ####\r\n\r\nVia npm:\r\n\r\n```\r\nnpm install errno-codes\r\n```\r\n\r\nOr simply copying `build/error.js` into your project's directory and `require()` accordingly.\r\n\r\n***\r\n\r\n<a name=\"compatibility\"></a>\r\n#### Compatibility [↑](#start) ####\r\n\r\n✔ Node *\r\n\r\n***\r\n\r\n<a name=\"documentation\"></a>\r\n#### Documentation [↑](#start) ####\r\n \r\n[Reference](https://github.com/Gagle/Node-Error/wiki/Reference) \r\n[Examples](https://github.com/Gagle/Node-Error/tree/master/examples) \r\n[Change Log](https://github.com/Gagle/Node-Error/wiki/Change-Log) \r\n[MIT License](https://github.com/Gagle/Node-Error/blob/master/LICENSE)",
+ "_id": "errno-codes@1.0.1",
+ "dist": {
+ "shasum": "a9a3264d67600c0058f76edb19fbf4128ffb66ec"
+ },
"_from": "errno-codes@*"
}
View
11 test/tests/node_modules/buffered-writer/package.json
@@ -1,6 +1,6 @@
{
"name": "buffered-writer",
- "version": "0.1.10",
+ "version": "0.1.11",
"description": "Fully configurable buffered writer.",
"keywords": [
"buffer",
@@ -33,7 +33,10 @@
}
],
"main": "buffered-writer",
- "readme": "<a name=\"start\"></a>\r\n\r\nNode BufferedWriter\r\n===================\r\n\r\n#### Fully configurable buffered writer for node.js ####\r\n\r\n[Availability](#availability) | [Compatibility](#compatibility) | [Documentation](#documentation)\r\n\r\nVersion: 0.1.10\r\n\r\nWhen you need to write a file you typically write the content in little chunks at a time. To avoid multiple calls to the underlying I/O layer you need to use a piece of memory called \"buffer\", so instead of writting directly to the disk, you write to the buffer and when it is filled the content is written to disk. Doing this you win performance.\r\n\r\nThis library allows you to write files using internal buffers, so you don't have to worry about them.\r\n\r\n<a name=\"availability\"></a>\r\n#### Availability [↑](#start) ####\r\n\r\nVia npm:\r\n\r\n```\r\nnpm install buffered-writer\r\n```\r\n\r\nOr simply copying `build/buffered-writer.js` into your project's directory and `require()` accordingly.\r\n\r\n***\r\n\r\n<a name=\"compatibility\"></a>\r\n#### Compatibility [↑](#start) ####\r\n\r\n✔ Node 0.4.10+\r\n\r\n***\r\n\r\n<a name=\"documentation\"></a>\r\n#### Documentation [↑](#start) ####\r\n \r\n[Reference](https://github.com/Gagle/Node-BufferedWriter/wiki/Reference) \r\n[Examples](https://github.com/Gagle/Node-BufferedWriter/tree/master/examples) \r\n[Change Log](https://github.com/Gagle/Node-BufferedWriter/wiki/Change-Log) \r\n[MIT License](https://github.com/Gagle/Node-BufferedWriter/blob/master/LICENSE)",
- "_id": "buffered-writer@0.1.10",
- "_from": "buffered-writer"
+ "readme": "<a name=\"start\"></a>\r\n\r\nNode BufferedWriter\r\n===================\r\n\r\n#### Fully configurable buffered writer for node.js ####\r\n\r\n[Show me!](#showme) | [Availability](#availability) | [Compatibility](#compatibility) | [Documentation](#documentation)\r\n\r\nVersion: 0.1.11\r\n\r\nWhen you need to write a file you typically write the content in little chunks at a time. To avoid multiple calls to the underlying I/O layer you need to use a piece of memory called \"buffer\", so instead of writting directly to the disk, you write to the buffer and when it is filled the content is written to disk. Doing this you win performance.\r\n\r\nThis library allows you to write files using internal buffers, so you don't have to worry about them.\r\n\r\n<a name=\"showme\"></a>\r\n#### Show me! [↑](#start) ####\r\n\r\n```javascript\r\nvar BufferedWriter = require (\"buffered-writer\");\r\n\r\nnew BufferedWriter (\"file\")\r\n\t.on (\"error\", function (error){\r\n\t\tconsole.log (error);\r\n\t})\r\n\t\r\n\t.write ([0x00, 0x01, 0x02], 0, 3) //Writes 0x00, 0x01, 0x02\r\n\t.write (new Buffer ([0x03, 0x04]), 1, 1) //Writes 0x04\r\n\t.write (0x0506) //Writes 0x05, 0x06\r\n\t.close ();\r\n```\r\n\r\n***\r\n\r\n<a name=\"availability\"></a>\r\n#### Availability [↑](#start) ####\r\n\r\nVia npm:\r\n\r\n```\r\nnpm install buffered-writer\r\n```\r\n\r\n***\r\n\r\n<a name=\"compatibility\"></a>\r\n#### Compatibility [↑](#start) ####\r\n\r\n✔ Node 0.4.10+\r\n\r\n***\r\n\r\n<a name=\"documentation\"></a>\r\n#### Documentation [↑](#start) ####\r\n \r\n[Reference](https://github.com/Gagle/Node-BufferedWriter/wiki/Reference) \r\n[Examples](https://github.com/Gagle/Node-BufferedWriter/tree/master/examples) \r\n[Change Log](https://github.com/Gagle/Node-BufferedWriter/wiki/Change-Log) \r\n[MIT License](https://github.com/Gagle/Node-BufferedWriter/blob/master/LICENSE)",
+ "_id": "buffered-writer@0.1.11",
+ "dist": {
+ "shasum": "8ce270c1483872b4404e4e240aeeacfcb23eaeef"
+ },
+ "_from": "buffered-writer@0.1.11"
}

0 comments on commit 8e3d3e3

Please sign in to comment.
Something went wrong with that request. Please try again.