most-data/data-common

Methods

(static) dasherize(data)

"Dasherizes" the given string
Parameters:
Name Type Description
data string
Source:
Returns:
string

(static) debug(data)

Logs the given data if the process is running in debug mode
Parameters:
Name Type Description
data Error | string | Object | *
Source:

(static) isDefined(obj) → {boolean}

Checks if the specified object argument is not undefined or null.
Parameters:
Name Type Description
obj *
Source:
Returns:
Type
boolean

(static) isNullOrUndefined(obj) → {boolean}

Checks if the specified object argument is undefined or null.
Parameters:
Name Type Description
obj *
Source:
Returns:
Type
boolean

(static) log(data)

Logs the given data
Parameters:
Name Type Description
data Error | string | Object | *
Source:

(static) md5(value) → {string|undefined}

Converts the given value to the equivalent MD5 formatted string.
Parameters:
Name Type Description
value *
Source:
Returns:
Type
string | undefined

(static) randomChars(howMany, charsopt) → {string}

Returns a sequence of random characters
Parameters:
Name Type Attributes Description
howMany Number The length of the random sequence of characters
chars string <optional>
A sequence of characters to be used in random sequence
Source:
Returns:
Type
string

(static) randomInt(min, max)

Returns a random integer between a minimum and a maximum value
Parameters:
Name Type Description
min number
max number
Source: