/** * @return bool */ protected function getResult() { if ($this->account[0] != 0) { return $this->validator->isValid($this->account); } $set = (int) substr($this->account, 0, 3); return $set >= 1 && $set <= 9; }
/** * @param string $account * @return bool */ public function isValid($account) { if (parent::isValid($account)) { return true; } $account = ltrim($account, '0') . '00'; return strlen($account) <= $this->normalizedSize && parent::isValid($account); }
public function isValid($account) { // 8-stellige Kontonummern sind nicht prüfbar $trimedAccount = ltrim($account, "0"); if (strlen($trimedAccount) === 8) { return true; } return parent::isValid($account); }
protected function validate() { if (in_array($this->account[0], [6, 7, 8, 9])) { $this->result = false; return; } $validator = new Validator00($this->bank); $validator->doNormalization = false; $prefixedAccount = self::$prefixes[$this->account[0]] . substr($this->account, 1); $this->result = $validator->isValid($prefixedAccount); }
public function isValid($account) { $this->checkType($account); $account = ltrim($account, '0'); $length = strlen($account); if ($length < 6 || $length > 9) { return false; } if ($length == 9) { if ($account[0] == 9) { $account = substr($account, 1, 6); } else { $account = substr($account, 0, 6); } } return parent::isValid($account); }
/** * @return bool */ protected function getResult() { return in_array($this->account[0], array_keys(self::$transformation)) ? $this->validator->isValid($this->transformedAccount) : false; }
/** * @return bool */ protected function getResult() { return $this->account[0] != 0 && $this->validator->isValid($this->transformedAccount); }
/** * @return bool */ protected function getResult() { return !is_null($this->validator) && $this->validator->isValid($this->account); }
/** * @return bool */ protected function getResult() { return array_key_exists($this->getTransformationIndex(), self::$transformation) && $this->validator->isValid($this->transformedAccount); }
public function isValid($account) { return strlen($account) >= 2 && parent::isValid($account); }
/** * @param string $account * @return bool */ public function isValid($account) { return (int) $account <= 999999999 ? $this->validator00->isValid($account) : parent::isValid($account); }