Skip to content

Commit c50fa58

Browse files
committed
Update namespace
1 parent 47d283e commit c50fa58

File tree

3 files changed

+13
-1
lines changed
  • lib/node_modules/@stdlib

3 files changed

+13
-1
lines changed

lib/node_modules/@stdlib/namespace/lib/namespace/r.js

+10
Original file line numberDiff line numberDiff line change
@@ -268,6 +268,16 @@ ns.push({
268268
'related': []
269269
});
270270

271+
ns.push({
272+
'alias': 'reviveBuffer',
273+
'path': '@stdlib/types/buffer/reviver',
274+
'value': require( '@stdlib/types/buffer/reviver' ),
275+
'type': 'Function',
276+
'related': [
277+
'@stdlib/types/buffer/to-json'
278+
]
279+
});
280+
271281
ns.push({
272282
'alias': 'reviveComplex',
273283
'path': '@stdlib/types/complex/reviver',

lib/node_modules/@stdlib/repl/code-blocks/lib/db.js

+1
Original file line numberDiff line numberDiff line change
@@ -1196,6 +1196,7 @@ module.exports = {
11961196
"resolveParentPath": "function onPath( error, path ) {\n if ( error ) {\n console.error( error.message );\n } else {\n console.log( path );\n }\n};\nresolveParentPath( 'package.json', onPath );\n",
11971197
"reverseArguments": "function foo( a, b, c ) { return [ a, b, c ]; };\nbar = reverseArguments( foo );\nout = bar( 1, 2, 3 )\n",
11981198
"reverseString": "out = reverseString( 'foo' )\nout = reverseString( 'abcdef' )\n",
1199+
"reviveBuffer": "str = '{\"type\":\"Buffer\",\"data\":[5,3]}';\nbuf = parseJSON( str, reviveBuffer )\n",
11991200
"reviveComplex": "str = '{\"type\":\"Complex128\",\"re\":5,\"im\":3}';\nz = parseJSON( str, reviveComplex )\n",
12001201
"reviveComplex128": "str = '{\"type\":\"Complex128\",\"re\":5,\"im\":3}';\nz = parseJSON( str, reviveComplex128 )\n",
12011202
"reviveComplex64": "str = '{\"type\":\"Complex64\",\"re\":5,\"im\":3}';\nz = parseJSON( str, reviveComplex64 )\n",

lib/node_modules/@stdlib/repl/help/lib/db.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -729,7 +729,7 @@ module.exports = {
729729
"bifurcateIn": "\nbifurcateIn( obj, [options,] predicate )\n Splits values into two groups according to a predicate function.\n\n When invoked, the predicate function is provided two arguments:\n\n - `value`: object value\n - `key`: object key\n\n If a predicate function returns a truthy value, a value is placed in the\n first group; otherwise, a value is placed in the second group.\n\n If provided an empty object with no prototype, the function returns an empty\n array.\n\n The function iterates over an object's own and inherited properties.\n\n Key iteration order is *not* guaranteed, and, thus, result order is *not*\n guaranteed.\n\n Parameters\n ----------\n obj: Object|Array|TypedArray\n Input object to group.\n\n options: Object (optional)\n Options.\n\n options.thisArg: any (optional)\n Execution context.\n\n options.returns: string (optional)\n If `values`, values are returned; if `keys`, keys are returned; if `*`,\n both keys and values are returned. Default: 'values'.\n\n predicate: Function\n Predicate function indicating which group a value in the input object\n belongs to.\n\n Returns\n -------\n out: Array<Array>|Array\n Group results.\n\n Examples\n --------\n > function Foo() { this.a = 'beep'; this.b = 'boop'; return this; };\n > Foo.prototype = Object.create( null );\n > Foo.prototype.c = 'foo';\n > Foo.prototype.d = 'bar';\n > var obj = new Foo();\n > function predicate( v ) { v[ 0 ] === 'b' };\n > var out = bifurcateIn( obj, predicate )\n [ [ 'beep', 'boop', 'bar' ], [ 'foo' ] ]\n\n // Output group results as keys:\n > var opts = { 'returns': 'keys' };\n > out = bifurcateIn( obj, opts, predicate )\n [ [ 'a', 'b', 'd' ], [ 'c' ] ]\n\n // Output group results as key-value pairs:\n > opts = { 'returns': '*' };\n > out = bifurcateIn( obj, opts, predicate )\n [ [ ['a', 'beep'], ['b', 'boop'], ['d', 'bar'] ], [ ['c', 'foo' ] ] ]\n\n See Also\n --------\n bifurcate, bifurcateBy, bifurcateOwn, groupIn\n",
730730
"bifurcateOwn": "\nbifurcateOwn( obj, [options,] predicate )\n Splits values into two groups according to a predicate function.\n\n When invoked, the predicate function is provided two arguments:\n\n - `value`: object value\n - `key`: object key\n\n If a predicate function returns a truthy value, a value is placed in the\n first group; otherwise, a value is placed in the second group.\n\n If provided an empty object, the function returns an empty array.\n\n The function iterates over an object's own properties.\n\n Key iteration order is *not* guaranteed, and, thus, result order is *not*\n guaranteed.\n\n Parameters\n ----------\n obj: Object|Array|TypedArray\n Input object to group.\n\n options: Object (optional)\n Options.\n\n options.thisArg: any (optional)\n Execution context.\n\n options.returns: string (optional)\n If `values`, values are returned; if `keys`, keys are returned; if `*`,\n both keys and values are returned. Default: 'values'.\n\n predicate: Function\n Predicate function indicating which group a value in the input object\n belongs to.\n\n Returns\n -------\n out: Array<Array>|Array\n Group results.\n\n Examples\n --------\n > function predicate( v ) { v[ 0 ] === 'b' };\n > var obj = { 'a': 'beep', 'b': 'boop', 'c': 'foo', 'd': 'bar' };\n > var out = bifurcateOwn( obj, predicate )\n [ [ 'beep', 'boop', 'bar' ], [ 'foo' ] ]\n\n // Output group results as keys:\n > var opts = { 'returns': 'keys' };\n > out = bifurcateOwn( obj, opts, predicate )\n [ [ 'a', 'b', 'd' ], [ 'c' ] ]\n\n // Output group results as key-value pairs:\n > opts = { 'returns': '*' };\n > out = bifurcateOwn( obj, opts, predicate )\n [ [ ['a', 'beep'], ['b', 'boop'], ['d', 'bar'] ], [ ['c', 'foo' ] ] ]\n\n See Also\n --------\n bifurcate, bifurcateBy, bifurcateIn, groupOwn\n",
731731
"Buffer": "\nBuffer\n Buffer constructor.\n\n\nBuffer( size )\n Allocates a buffer having a specified number of bytes.\n\n Parameters\n ----------\n size: integer\n Number of bytes to allocate.\n\n Returns\n -------\n out: Buffer\n Buffer instance.\n\n Examples\n --------\n > var b = new Buffer( 4 )\n <Buffer>\n\n\nBuffer( buffer )\n Copies buffer data to a new Buffer instance.\n\n Parameters\n ----------\n buffer: Buffer\n Buffer to copy from.\n\n Returns\n -------\n out: Buffer\n Buffer instance.\n\n Examples\n --------\n > var b1 = new Buffer( [ 1, 2, 3, 4 ] );\n > var b2 = new Buffer( b1 )\n <Buffer>[ 1, 2, 3, 4 ]\n\n\nBuffer( array )\n Allocates a buffer using an array of octets.\n\n Parameters\n ----------\n array: Array\n Array of octets.\n\n Returns\n -------\n out: Buffer\n Buffer instance.\n\n Examples\n --------\n > var b = new Buffer( [ 1, 2, 3, 4 ] )\n <Buffer>[ 1, 2, 3, 4 ]\n\n\nBuffer( str[, encoding] )\n Allocates a buffer containing a provided string.\n\n Parameters\n ----------\n str: string\n Input string.\n\n encoding: string (optional)\n Character encoding. Default: 'utf8'.\n\n Returns\n -------\n out: Buffer\n Buffer instance.\n\n Examples\n --------\n > var b = new Buffer( 'beep boop' )\n <Buffer>\n\n\nTODO: add methods and properties\n\n\n See Also\n --------\n ArrayBuffer\n",
732-
"buffer2json": "\nbuffer2json( buffer )\n Returns a JSON representation of a buffer.\n\n The returned JSON object has the following properties:\n\n - type: value type\n - data: buffer data as a generic array\n\n Parameters\n ----------\n buffer: Buffer\n Buffer to serialize.\n\n Returns\n -------\n out: Object\n JSON representation.\n\n Examples\n --------\n > var buf = new allocUnsafe( 2 );\n > buf[ 0 ] = 1;\n > buf[ 1 ] = 2;\n > var json = buffer2json( buf )\n { 'type': 'Buffer', 'data': [ 1, 2 ] }\n\n See Also\n --------\n typedarray2json\n",
732+
"buffer2json": "\nbuffer2json( buffer )\n Returns a JSON representation of a buffer.\n\n The returned JSON object has the following properties:\n\n - type: value type\n - data: buffer data as a generic array\n\n Parameters\n ----------\n buffer: Buffer\n Buffer to serialize.\n\n Returns\n -------\n out: Object\n JSON representation.\n\n Examples\n --------\n > var buf = new allocUnsafe( 2 );\n > buf[ 0 ] = 1;\n > buf[ 1 ] = 2;\n > var json = buffer2json( buf )\n { 'type': 'Buffer', 'data': [ 1, 2 ] }\n\n See Also\n --------\n typedarray2json, reviveBuffer\n",
733733
"capitalize": "\ncapitalize( str )\n Capitalizes the first character in a `string`.\n\n Parameters\n ----------\n str: string\n Input string.\n\n Returns\n -------\n out: string\n Capitalized string.\n\n Examples\n --------\n > var out = capitalize( 'beep' )\n 'Beep'\n > out = capitalize( 'Boop' )\n 'Boop'\n\n See Also\n --------\n uncapitalize, uppercase\n",
734734
"capitalizeKeys": "\ncapitalizeKeys( obj )\n Converts the first letter of each object key to uppercase.\n\n The function only transforms own properties. Hence, the function does not\n transform inherited properties.\n\n The function shallow copies key values.\n\n Parameters\n ----------\n obj: Object\n Source object.\n\n Returns\n -------\n out: Object\n New object.\n\n Examples\n --------\n > var obj = { 'aa': 1, 'bb': 2 };\n > var out = capitalizeKeys( obj )\n { 'Aa': 1, 'Bb': 2 }\n\n See Also\n --------\n uncapitalizeKeys, uppercaseKeys\n",
735735
"CATALAN": "\nCATALAN\n Catalan's constant.\n\n Examples\n --------\n > CATALAN\n 0.915965594177219\n\n",
@@ -1196,6 +1196,7 @@ module.exports = {
11961196
"resolveParentPath": "\nresolveParentPath( path[, options,] clbk )\n Asynchronously resolves a path by walking parent directories.\n\n If unable to resolve a path, the function returns `null` as the path result.\n\n Parameters\n ----------\n path: string\n Path to resolve.\n\n options: Object (optional)\n Options.\n\n options.dir: string (optional)\n Base directory from which to search. Default: current working directory.\n\n clbk: Function\n Callback to invoke after resolving a path.\n\n Examples\n --------\n > function onPath( error, path ) {\n ... if ( error ) {\n ... console.error( error.message );\n ... } else {\n ... console.log( path );\n ... }\n ... };\n > resolveParentPath( 'package.json', onPath );\n\n\nresolveParentPath.sync( path[, options] )\n Synchronously resolves a path by walking parent directories.\n\n Parameters\n ----------\n path: string\n Path to resolve.\n\n options: Object (optional)\n Options.\n\n options.dir: string (optional)\n Base directory from which to search. Default: current working directory.\n\n Returns\n -------\n out: string|null\n Resolved path.\n\n Examples\n --------\n > var out = resolveParentPath.sync( 'package.json' );\n\n",
11971197
"reverseArguments": "\nreverseArguments( fcn[, thisArg] )\n Returns a function that invokes a provided function with arguments in\n reverse order.\n\n Parameters\n ----------\n fcn: Function\n Input function.\n\n thisArg: any (optional)\n Function context.\n\n Returns\n -------\n out: Function\n Function with reversed arguments.\n\n Examples\n --------\n > function foo( a, b, c ) { return [ a, b, c ]; };\n > var bar = reverseArguments( foo );\n > var out = bar( 1, 2, 3 )\n [ 3, 2, 1 ]\n\n See Also\n --------\n reorderArguments\n",
11981198
"reverseString": "\nreverseString( str )\n Reverses a `string`.\n\n Parameters\n ----------\n str: string\n Input string.\n\n Returns\n -------\n out: string\n Reversed string.\n\n Examples\n --------\n > var out = reverseString( 'foo' )\n 'oof'\n > out = reverseString( 'abcdef' )\n 'fedcba'\n\n",
1199+
"reviveBuffer": "\nreviveBuffer( key, value )\n Revives a JSON-serialized Buffer.\n\n The serialization format for a Buffer is an object having the following\n fields:\n\n - type: value type (Buffer)\n - data: buffer data as an array of integers\n\n Parameters\n ----------\n key: string\n Key.\n\n value: any\n Value.\n\n Returns\n -------\n out: any\n Value or Buffer.\n\n Examples\n --------\n > var str = '{\"type\":\"Buffer\",\"data\":[5,3]}';\n > var buf = parseJSON( str, reviveBuffer )\n <Buffer>[ 5, 3 ]\n\n See Also\n --------\n buffer2json\n",
11991200
"reviveComplex": "\nreviveComplex( key, value )\n Revives a JSON-serialized complex number.\n\n The serialization format for complex numbers is an object having the\n following fields:\n\n - type: complex number type (e.g., \"Complex128\", \"Complex64\")\n - re: real component (number)\n - im: imaginary component (number)\n\n Parameters\n ----------\n key: string\n Key.\n\n value: any\n Value.\n\n Returns\n -------\n out: any\n Value or complex number.\n\n Examples\n --------\n > var str = '{\"type\":\"Complex128\",\"re\":5,\"im\":3}';\n > var z = parseJSON( str, reviveComplex )\n <Complex128>\n\n See Also\n --------\n Complex128, Complex64, reviveComplex128, reviveComplex64\n",
12001201
"reviveComplex128": "\nreviveComplex128( key, value )\n Revives a JSON-serialized 128-bit complex number.\n\n Parameters\n ----------\n key: string\n Key.\n\n value: any\n Value.\n\n Returns\n -------\n out: any\n Value or complex number.\n\n Examples\n --------\n > var str = '{\"type\":\"Complex128\",\"re\":5,\"im\":3}';\n > var z = parseJSON( str, reviveComplex128 )\n <Complex128>\n\n See Also\n --------\n Complex128, reviveComplex64, reviveComplex\n",
12011202
"reviveComplex64": "\nreviveComplex64( key, value )\n Revives a JSON-serialized 64-bit complex number.\n\n Parameters\n ----------\n key: string\n Key.\n\n value: any\n Value.\n\n Returns\n -------\n out: any\n Value or complex number.\n\n Examples\n --------\n > var str = '{\"type\":\"Complex64\",\"re\":5,\"im\":3}';\n > var z = parseJSON( str, reviveComplex64 )\n <Complex64>\n\n See Also\n --------\n Complex64, reviveComplex128, reviveComplex\n",

0 commit comments

Comments
 (0)