All files / src matchers.js

100% Statements 1/1
100% Branches 0/0
100% Functions 0/0
100% Lines 1/1
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37        7x                                                                
import * as normal from './ruleHandlers/generalRules';
import * as number from './ruleHandlers/numberRules';
import * as string from './ruleHandlers/stringRules';
 
const handlerMatcher = {
  /* String handlers */
  minLength: string.minLength,
  maxLength: string.maxLength,
  include: string.include,
  exclude: string.exclude,
  startWith: string.startWith,
  notStartWith: string.notStartWith,
  endWith: string.endWith,
  notEndWith: string.notEndWith,
 
  /* Number handlers */
  min: number.min,
  max: number.max,
  equal: number.equal,
  notEqual: number.notEqual,
  isPositive: number.isPositive,
  isNegative: number.isNegative,
  isInt: number.isInt,
 
  /* Normal handlers */
  enum: normal.enumRule,
  matchRegex: normal.matchRegex,
  isEmail: normal.isEmail,
  isUrl: normal.isUrl,
  isCreditCard: normal.isCreditCard,
  isHexColor: normal.isHexColor,
  notEmpty: normal.notEmpty,
  isIP: normal.isIP
};
 
export default handlerMatcher;