UNPKG

dinoloop-es8

Version:

A lightweight REST API Library for building scalable Node.js server-side applications powered by Typescript

26 lines (25 loc) 1 kB
import { IConversionValidation } from '../types'; /** * Wrapper methods to test the datatype of the given value */ export declare abstract class DataUtility { static isUndefined(data: any): boolean; static isUndefinedOrNull(data: any): boolean; static isNull(data: any): boolean; static isEmpty(data: any): boolean; static isFunction(data: any): boolean; static isString(data: any): boolean; static isRegExp(data: any): boolean; static isBoolean(data: any): boolean; static isStrictBoolean(data: any): boolean; static isNumber(data: any): boolean; /** * Strict - does not use string conversion */ static isStrictNumber(data: any): boolean; static isArray(data: any): boolean; static isInteger(data: any): boolean; static toNumber(data: any): IConversionValidation<number>; static toInteger(data: any): IConversionValidation<number>; static toBoolean(data: any): IConversionValidation<boolean>; }