Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
98 changes: 98 additions & 0 deletions lib/node_modules/@stdlib/ndarray/base/assert/docs/types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@

import hasEqualShape = require( '@stdlib/ndarray/base/assert/has-equal-shape' );
import isAllowedDataTypeCast = require( '@stdlib/ndarray/base/assert/is-allowed-data-type-cast' );
import isBinaryDataType = require( '@stdlib/ndarray/base/assert/is-binary-data-type' );
import isBooleanDataType = require( '@stdlib/ndarray/base/assert/is-boolean-data-type' );
import isBooleanIndexDataType = require( '@stdlib/ndarray/base/assert/is-boolean-index-data-type' );
import isBufferLengthCompatible = require( '@stdlib/ndarray/base/assert/is-buffer-length-compatible' );
Expand All @@ -38,6 +39,7 @@ import isDataTypeObject = require( '@stdlib/ndarray/base/assert/is-data-type-obj
import isDataTypeString = require( '@stdlib/ndarray/base/assert/is-data-type-string' );
import isEqualDataType = require( '@stdlib/ndarray/base/assert/is-equal-data-type' );
import isFloatingPointDataType = require( '@stdlib/ndarray/base/assert/is-floating-point-data-type' );
import isGenericDataType = require( '@stdlib/ndarray/base/assert/is-generic-data-type' );
import isIndexDataType = require( '@stdlib/ndarray/base/assert/is-index-data-type' );
import isIndexMode = require( '@stdlib/ndarray/base/assert/is-index-mode' );
import isInputCastingPolicy = require( '@stdlib/ndarray/base/assert/is-input-casting-policy' );
Expand Down Expand Up @@ -101,6 +103,54 @@ interface Namespace {
*/
isAllowedDataTypeCast: typeof isAllowedDataTypeCast;

/**
* Tests whether an input value is a supported ndarray binary data type.
*
* @param v - value to test
* @returns boolean indicating whether an input value is a supported ndarray binary data type
*
* @example
* var bool = ns.isBinaryDataType( 'binary' );
* // returns true
*
* bool = ns.isBinaryDataType( 'bool' );
* // returns false
*
* bool = ns.isBinaryDataType( 'float32' );
* // returns false
*
* bool = ns.isBinaryDataType( 'float64' );
* // returns false
*
* bool = ns.isBinaryDataType( 'generic' );
* // returns false
*
* bool = ns.isBinaryDataType( 'int16' );
* // returns false
*
* bool = ns.isBinaryDataType( 'int32' );
* // returns false
*
* bool = ns.isBinaryDataType( 'int8' );
* // returns false
*
* bool = ns.isBinaryDataType( 'uint16' );
* // returns false
*
* bool = ns.isBinaryDataType( 'uint32' );
* // returns false
*
* bool = ns.isBinaryDataType( 'uint8' );
* // returns false
*
* bool = ns.isBinaryDataType( 'uint8c' );
* // returns false
*
* bool = ns.isBinaryDataType( 'foo' );
* // returns false
*/
isBinaryDataType: typeof isBinaryDataType;

/**
* Tests whether an input value is a supported ndarray boolean data type.
*
Expand Down Expand Up @@ -663,6 +713,54 @@ interface Namespace {
*/
isFloatingPointDataType: typeof isFloatingPointDataType;

/**
* Tests whether an input value is a supported ndarray generic data type.
*
* @param v - value to test
* @returns boolean indicating whether an input value is a supported ndarray generic data type
*
* @example
* var bool = ns.isGenericDataType( 'binary' );
* // returns false
*
* bool = ns.isGenericDataType( 'bool' );
* // returns false
*
* bool = ns.isGenericDataType( 'float32' );
* // returns false
*
* bool = ns.isGenericDataType( 'float64' );
* // returns false
*
* bool = ns.isGenericDataType( 'generic' );
* // returns true
*
* bool = ns.isGenericDataType( 'int16' );
* // returns false
*
* bool = ns.isGenericDataType( 'int32' );
* // returns false
*
* bool = ns.isGenericDataType( 'int8' );
* // returns false
*
* bool = ns.isGenericDataType( 'uint16' );
* // returns false
*
* bool = ns.isGenericDataType( 'uint32' );
* // returns false
*
* bool = ns.isGenericDataType( 'uint8' );
* // returns false
*
* bool = ns.isGenericDataType( 'uint8c' );
* // returns false
*
* bool = ns.isGenericDataType( 'foo' );
* // returns false
*/
isGenericDataType: typeof isGenericDataType;

/**
* Tests whether an input value is a supported ndarray index data type.
*
Expand Down