buffer.writeIntLE()

buf.writeIntLE(value, offset, byteLength[, noAssert]) value <Number> Bytes to be written to Buffer offset <Number> 0 <= offset <= buf.length - byteLength byteLength <Number> 0 < byteLength <= 6 noAssert <Boolean> Default: false Return: <Number> The offset plus the number of written bytes Writes value to the Buffer at the specified offset and byteLength. Supports up to 48 bits of accuracy. For example: const buf1 = Buffer.allocUnsafe(6); buf1.wr

certificate.exportChallenge()

certificate.exportChallenge(spkac) The spkac data structure includes a public key and a challenge. The certificate.exportChallenge() returns the challenge component in the form of a Node.js Buffer. The spkac argument can be either a string or a Buffer. const cert = require('crypto').Certificate(); const spkac = getSpkacSomehow(); const challenge = cert.exportChallenge(spkac); console.log(challenge.toString('utf8')); // Prints the challenge as a UTF8 string

buffer.swap16()

buf.swap16() Return: <Buffer> Interprets the Buffer as an array of unsigned 16-bit integers and swaps the byte-order in-place. Throws a RangeError if the Buffer length is not a multiple of 16 bits. The method returns a reference to the Buffer, so calls can be chained. const buf = Buffer.from([0x1, 0x2, 0x3, 0x4, 0x5, 0x6, 0x7, 0x8]); console.log(buf); // Prints Buffer(0x1, 0x2, 0x3, 0x4, 0x5, 0x6, 0x7, 0x8) buf.swap16(); console.log(buf); // Prints Buffer(0x2, 0x1, 0x4, 0x3, 0x6,

cluster.schedulingPolicy

cluster.schedulingPolicy The scheduling policy, either cluster.SCHED_RR for round-robin or cluster.SCHED_NONE to leave it to the operating system. This is a global setting and effectively frozen once you spawn the first worker or call cluster.setupMaster(), whatever comes first. SCHED_RR is the default on all operating systems except Windows. Windows will change to SCHED_RR once libuv is able to effectively distribute IOCP handles without incurring a large performance hit. cluster.schedulingP

cipher.setAAD()

cipher.setAAD(buffer) When using an authenticated encryption mode (only GCM is currently supported), the cipher.setAAD() method sets the value used for the additional authenticated data (AAD) input parameter.

childprocess.disconnect()

child.disconnect() Closes the IPC channel between parent and child, allowing the child to exit gracefully once there are no other connections keeping it alive. After calling this method the child.connected and process.connected properties in both the parent and child (respectively) will be set to false, and it will be no longer possible to pass messages between the processes. The 'disconnect' event will be emitted when there are no messages in the process of being received. This will most ofte

buffer.writeInt16LE()

buf.writeInt16LE(value, offset[, noAssert]) value <Number> Bytes to be written to Buffer offset <Number> 0 <= offset <= buf.length - 2 noAssert <Boolean> Default: false Return: <Number> The offset plus the number of written bytes Writes value to the Buffer at the specified offset with specified endian format (writeInt16BE() writes big endian, writeInt16LE() writes little endian). The value should be a valid signed 16-bit integer. Behavior is not defined when

SlowBuffer

Class: SlowBuffer Returns an un-pooled Buffer. In order to avoid the garbage collection overhead of creating many individually allocated Buffers, by default allocations under 4KB are sliced from a single larger allocated object. This approach improves both performance and memory usage since v8 does not need to track and cleanup as many Persistent objects. In the case where a developer may need to retain a small chunk of memory from a pool for an indeterminate amount of time, it may be appropr

Buffer.concat()

Class Method: Buffer.concat(list[, totalLength]) list <Array> List of Buffer objects to concat totalLength <Number> Total length of the Buffers in the list when concatenated Return: <Buffer> Returns a new Buffer which is the result of concatenating all the Buffers in the list together. If the list has no items, or if the totalLength is 0, then a new zero-length Buffer is returned. If totalLength is not provided, it is calculated from the Buffers in the list. This, howev

process.arch

process.arch What processor architecture you're running on: 'arm', 'ia32', or 'x64'. console.log('This processor architecture is ' + process.arch);