VOOZH about

URL: https://www.geeksforgeeks.org/node-js/node-js-util-types-isint16array-method/

⇱ Node.js util.types.isInt16Array() Method - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

Node.js util.types.isInt16Array() Method

Last Updated : 28 Apr, 2025

The util.types.isInt16Array() method is an inbuilt application programming interface of the util module which is used to check the type for Int16Array in the node.js. 

Syntax:

util.types.isInt16Array( value )

Parameters: This method accepts a single parameter as mentioned above and described below.

  • value: It is a required parameter that holds any data type.

Return Value: It returns a boolean value, TRUE if the value is an Int16Array object, FALSE otherwise.  

Example 1: Below examples illustrate the use of util.types.isInt16Array() method in Node.js

Output:

false
false
false
false
true

Example 2: In this example, we illustrate the use of util.types.isInt16Array() method in Node.js

Output:

The passed value is not a Int16Array.
The passed value is a Int16Array

Note: The above program will compile and run by using the node filename.js command. 

Reference: https://nodejs.org/api/util.html#util_util_types_isint16array_value

Comment

Explore