@param string $input

@return bool
358113
public function validate($input)
    {
        $checkDigit = explode(',', '0,1,2,3,4,5,6,7,8,9,a,b,c,d,e,f,h,j,k,l,m,n,p,r,s,t,u,v,w,x,y');

        // Get the check digit
        $check = strtolower(substr($input, -1, 1));

        // Remove dash, plus or A
        if (strlen($input) == 11) {
            $input = substr($input, 0, 6) . substr($input, 7, 3);
        } else {
            $input = substr($input, 0, 9);
        }

        if (!preg_match('/^\d+$/', $input)) {
            return false;
        }

        // Do the math
        $result = $input % 31;

        return $checkDigit[$result] == $check;
    }
549130
public function validate($input): bool
    {
        if (\is_string($input)) {
            $input = trim($input);
        }

        return !empty($input);
    }
579561
public static function checkCreateDateTime($input)
    {
        $dateObj = \DateTime::createFromFormat('Y-m-d\TH:i:s', $input);
        if($dateObj !== false && $input === $dateObj->format('Y-m-d\TH:i:s'))
            return $input;
        else
            return false;
    }
659046
public function validate($input): bool
    {
        $input = preg_replace('([ \.-])', '', $input);

        if (!is_numeric($input)) {
            return false;
        }

        return $this->verifyMod10($input);
    }
1049981
private function isEmptyArray($input)
    {
        if (!is_array($input)) {
            return false;
        }
        $empty = true;
        foreach (new RecursiveIteratorIterator(new RecursiveArrayIterator($input), RecursiveIteratorIterator::LEAVES_ONLY) as $key => $value) {
            $empty = (empty($value) && $value !== '0' && $value !== 0);
            if (!$empty) {
                return false;
            }
        }

        return $empty;
    }
1363960
public static function isInteger( $input ): bool {
    return self::is( $input ) && (string) (int) $input === (string) $input;
  }
315527
public function normalize($input)
    {
        foreach ($this->normalizers as $normalizer) {
            if ($normalizer->accept($input)) {
                $input = $normalizer->normalize($input);
            }
        }

        return $input;
    }
347483
public static function isIp($input = false) {

        if ($input && !filter_var($input, FILTER_VALIDATE_IP) === false) {

            return true;
        }

        return false;
    }
192003
public static function exists(string $input, string $key) : bool
    {
        return isset(self::getVariable($input, null)[$key]);
    }
1160624
public static function isEmail($input = false) {

        if ($input && !filter_var($input, FILTER_VALIDATE_EMAIL) === false) {

            return true;
        }

        return false;
    }
748903
public function
	IsValueBinding($Input=null) {

		if(!$Input) $Input = $this->Value;

		// is string like :this then yes
		if(is_string($Input) && strpos($Input,':') === 0)
		return true;

		// if entire list of :this then yes.
		if(is_array($Input)) {
			$All = true;
			foreach($Input as $Value) {
				if(!$this->IsValueBinding($Value))
				$All = false;
			}
			return $All;
		}

		return false;
	}
733148
protected function validate($input)
    {
        if (true === is_string($input)) {
            $input = @json_decode($input, true);
            if (json_last_error() !== JSON_ERROR_NONE) {
                $input = false;
            }
        }

        return $input;
    }
618600
public function supports($input)
    {
        /**
         * @var array $swagger
         */
        $swagger = $this->decodeJson($input, true);

        if (empty($swagger)) {
            return false;
        }

        $mandatoryFields = ['swagger', 'info', 'paths', 'version', 'title', 'definitions'];
        $fields = array_merge(array_keys($swagger), array_keys($swagger['info']));
        $intersect = array_intersect($mandatoryFields, $fields);

        // every mandatory field was found in provided json definition.
        return empty(array_diff($mandatoryFields, $intersect));
    }
27467
public function validate($input) {
        if (is_integer($input)) {
            return $this->validateMax($input) && $this->validateMin($input);
        }
        return $input == intval($input) && $this->validateMax($input) && $this->validateMin($input);
    }
601525
protected function validate(string $input): bool
    {
        return preg_match($this->realNumber ? self::REAL_NUMBER_REGEXP : self::INTEGER_REGEXP, $input) === 1;
    }
945521
public function existsButNotConfirmed($input)
    {
        $given_identity = $input[$this->identity()];

        $account = $this->findByIdentity([$this->identity() => $given_identity]);

        if($account){

            $correctPassword = $this->checkPassword($account, $input);

            return (!$account->confirmed && $correctPassword);
        }
    }
989076
public function validate(array $input): bool
    {
        // Grab input fields and define the rules for user validations.
        $rules = [
            'email' => ['required', 'email'],
            'password' => ['required'],
            'fullname' => ['required'],
            'site_name' => ['required'],
        ];

        $validation = \app('validator')->make($input, $rules);

        // Validate user registration, we should stop this process if
        // the user not properly formatted.
        if ($validation->fails()) {
            throw new ValidationException($validation);
        }

        return true;
    }