@abstract    Verify inputs

@param array $input Array of Object Data ($Code => $Value)

@return bool
199796
private static function isValid($input)
    {
        if (!is_array($input)) {
            return false;
        }
        foreach ($input as $value) {
            if (!is_scalar($value)) {
                return false;
            }
        }

        return true;
    }
1035784
public function sanitizeInput(array $input)
    {
        return $input = collect($input)->reject(function ($value) {
            return is_null($value) || empty($value);
        })->toArray();
    }
905265
public function validate($input): bool
    {
        if (false !== strpos($input, '--')) {
            return false;
        }

        if (!preg_match('/^[0-9a-z\-]+$/', $input)) {
            return false;
        }

        if (preg_match('/^-|-$/', $input)) {
            return false;
        }

        return true;
    }
1336715
public function validate($input): bool
    {
        if (is_array($input) === false && ($input instanceof Generator) === false) {
            throw new InvalidArgumentException();
        }

        if ($this->areAggregatorsDirty() === true) {
            $this->resetAggregators();
        }

        $this->validateAttributes($input)->markAggregatorsAsDirty();

        $hasNoErrors = $this->getErrorAggregator()->count() <= 0;

        return $hasNoErrors;
    }
939596
protected function authenticate(array $input)
    {
        $remember = (($input['remember'] ?? 'no') === 'yes');

        $data = Arr::except($input, ['remember']);

        // We should now attempt to login the user using Auth class. If this
        // failed simply return false.
        return $this->auth->attempt($data, $remember);
    }
1371430
public function process(array $input)
    {
        if($this->v->validate($input))
        {
            Event::fire("form.processing", array($input));
            return $this->callRepository($input);
        }
        else
        {
            $this->errors = $this->v->getErrors();
            throw new ValidationException;
        }
    }
1222881
protected function validate(string $input): bool
    {
        return \Normalizer::isNormalized($input, \Normalizer::FORM_KC)
            && ($this->isRegExp($input) ? $this->validateRegexp($input) : $this->validateCharacters($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));
    }
283466
public function verifySalt($input)
    {
        $regex = '/^\$' . $this->_identifier . '\$(?:rounds=(\d{4,9})\$)?([\.\/0-9A-Za-z]{0,16})\$?$/';
        $matches = array ();

        $appearsValid = (1 === preg_match($regex, $input, $matches));
        if ($appearsValid) {
            $rounds = (int) $matches[1];
            $salt = $matches[2];

            // If rounds parameter is in the salt position, the configuration
            // is probably not what the user intends. We could let it pass and
            // it'll "work", but we'll fail it for now.
            if (strpos($salt, 'rounds=') === 0) {
                $appearsValid = false;
            }

            if (!empty ($matches[1]) && ($rounds < 1000 || $rounds > 999999999)) {
                $appearsValid = false;
            }
        }

        return $appearsValid;
    }
166261
public function validate($input): bool
    {
        if ($input instanceof DateTime) {
            return true;
        }

        if (!\is_string($input)) {
            return false;
        }

        if (null === $this->format) {
            return false !== strtotime($input);
        }

        $dateFromFormat = DateTime::createFromFormat($this->format, $input);

        return $dateFromFormat
            && $input === date($this->format, $dateFromFormat->getTimestamp());
    }
1130789
protected static function hasClassIdentifierKey(array $input)
    {
        if (!empty($input[Serializer::CLASS_IDENTIFIER_KEY])) {
            return true;
        }

        $foundIdentifierKey = false;
        if (!empty($input[Serializer::SCALAR_VALUE]) && !empty($input[Serializer::MAP_TYPE])) {
            $input = $input[Serializer::SCALAR_VALUE];
            if (\is_array($input)) {
                foreach ($input as $value) {
                    if (\is_array($value)) {
                        $foundIdentifierKey = $foundIdentifierKey || self::hasClassIdentifierKey($value);
                    }
                }
            }
        }

        return $foundIdentifierKey;
    }
178827
public function match($input)
    {
        if (!is_string($input)) {
            throw new \InvalidArgumentException(
                'Invalid argument. Expected a string, received ' . gettype($input)
            );
        }

        return (bool) preg_match('/' . $this->getRule() . '/ms', strtolower($input));
    }
511595
public function validate($input): bool
    {
        $this->exception = new ValidatorException();

        // run chains
        foreach ($this->validators as $key => $validators) {
            // skip validation for non required elements
            if (!isset($input[$key]) && !$validators->isRequired()) {
                continue;
            }
            $this->validateItem($key, $input[$key] ?? null);
        }

        return !$this->hasErrors();
    }
450176
public function validate($input): bool
    {
        if (!$length = $this->extractLength($input)) {
            return false;
        }

        return (null === $this->minValue || $this->less($this->minValue, $length))
            && (null === $this->maxValue || $this->less($length, $this->maxValue));
    }
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;
    }
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;
    }
1103501
public function verify($inputs)
    {
        $result = $this->restCall('PaymentVerification.json', $inputs);

        if ($result['Status'] == 100 || $result['Status'] == 101) {
            return ['Status' => 'success', 'RefID' => $result['RefID']];
        } else {
            return ['Status' => 'error', 'error' => $result['Status']];
        }
    }