Class: Validator

Validator

new Validator()

Represents a validator library for the Jira Connector

Source:

Methods

isLowerCase(value, requirement, attribute) → {string}

ensure data is lowerCase

Parameters:
Name Type Description
value *

The value to be validated

requirement *

requirement parameter defaults to null

attribute string

the attribute to validate

Source:
Returns:

the encrypted data

Type
string

isUpperCase(value, requirement, attribute) → {string}

ensure data is uppercase

Parameters:
Name Type Description
value *

The value to be validated

requirement *

requirement parameter defaults to null

attribute string

the attribute to validate

Source:
Returns:

the encrypted data

Type
string

validate(data, rules) → {boolean|array}

validate data with the ruleset

Parameters:
Name Type Description
data Object

The data to be validated

rules Object

the rules object

Source:
Returns:

the validation result (true === passed, array === list of errors)

Type
boolean | array