Indica si la variable se puede expresar como una cadena de texto

@return bool
486286
public function isConvertibleToString(): bool
    {
        $isConvertible = $this->isScalar() || $this->isTypeOf(Stringifable::class) || $this->isNull();

        if ($isConvertible) {
            return true;
        }

        $hasToStringMethod = method_exists($this->variable, '__toString');

        return $hasToStringMethod;
    }
232220
public function check() {
    foreach( $this->dictionary as $word ):
      $rule = "alone";
      if( is_array($word) ) {
        $rule = isset($word[1]) ? $word[1] : $rule;
        $word = $word[0];
      }
      $word = preg_replace("/([^\w ]*)/iu", "", $word);
      if( "among" === $rule ) {
        if( preg_match("/(" . $word . ")/iu", $this->text ) ) return true;
      } else {
        if( preg_match("/(\b)+(" . $word . ")+(\b)/iu", $this->text ) ) return true;
      }
    endforeach;
    return false;
  }
249423
public function isReadable()
    {
        if (null !== ($mode = $this->getMetadata('mode'))) {
            preg_match_all('/[a-z]\D?/', $mode, $matches);

            if (isset($matches[ 0 ])) {
                foreach ($matches[ 0 ] as $match) {
                    if (in_array($match, ['r', 'r+', 'w+', 'a+', 'x+', 'c+'])) {
                        return true;
                        break;
                    }
                }
            }
        }

        return false;
    }
112752
public function key()
    {
        if (null === $this->singular || '' === $this->singular) {
            return false;
        }

        // Prepend context and EOT, like in MO files
        $key = !$this->context ? $this->singular : $this->context . chr(4) . $this->singular;
        // Standardize on \n line endings
        $key = str_replace(array("\r\n", "\r"), "\n", $key);

        return $key;
    }
1066489
private function _checkComplexVariable($token) {
		if ($this->tokenizer->checkNextToken(T_BRACES_OPEN)) {

			// Detect the end of the complexe variable
			$closePos = $this->tokenizer->findNextTokenPosition(T_BRACES_CLOSE);

			if ($closePos !== null) {

				// Skip the analysis of the content of the variable.
				$this->tokenizer->setCurrentPosition($closePos + 1);

				return true;
			}
		}

		return false;
	}
320745
public function isVariant(): bool
    {
        $isVariant = false;
        if (isset($this->oxarticles__oxparentid) && false !== $this->oxarticles__oxparentid) {
            $isVariant = (bool) $this->oxarticles__oxparentid->value;
        }

        return $isVariant;
    }
649791
public function hasNext()
    {
        $cursor = $this;
        return $this->retry(function() use ($cursor) {
            return $cursor->getRiakCursor()->hasNext();
        }, false);
    }
1274254
protected function handleCharacter32()
    {
        $this->lastSpace = $this->currentIndex;

        if (!empty($this->keywordHashMap[$this->buildingWord]))
        {
            return true;
        }

        if ((chr($this->nextCharacter) . $this->input[$this->currentIndex + 2]) == 'in') {
            return true;
        }

        if ($this->inCondition) {
            return true;
        }

        if ($this->inQuotes) {
            return true;
        }

        if ($this->inSingleQuotes) {
            return true;
        }

        return false;
    }
73334
protected function validateTextReview()
    {
        $field = 'text';

        if ($this->isExcluded($field)) {
            return null;
        }

        $value = $this->getSubmitted($field);

        if ($this->isUpdating() && !isset($value)) {
            $this->unsetSubmitted($field);
            return null;
        }

        $label = $this->translation->text('Text');

        if (empty($value)) {
            $this->setErrorRequired($field, $label);
            return false;
        }

        $length = mb_strlen($value);
        list($min, $max) = $this->review->getLimits();

        if ($length < $min || $length > $max) {
            $this->setErrorLengthRange($field, $label, $min, $max);
            return false;
        }

        return true;
    }
19741
public function isLibra()
    {
        return ($this->month === self::MONTH_SEPTEMBER) && ($this->day >= 24) && ($this->day <= 30) || ($this->month === self::MONTH_OCTOBER) && ($this->day <= 23);
    }
841139
public function vigente()
    {
        if (!in_array($this->getTipo(), [33, 43, 46, 56, 61])) {
            return true;
        }
        $fecha_autorizacion = $this->getFechaAutorizacion();
        $hoy = date('Y-m-d');
        if ($fecha_autorizacion < '2018-07-01' and $hoy > '2018-12-31') {
            return false;
        }
        $vigencia = $fecha_autorizacion >= '2018-07-01' ? 6 : 18;
        $d1 = new \DateTime($fecha_autorizacion);
        $d2 = new \DateTime($hoy);
        $meses = $d1->diff($d2)->m + ($d1->diff($d2)->y*12);
        return $meses <= $vigencia;
    }
567128
public function step2()
    {
        if ( ($position = $this->searchIfInRv(array('и'))) !== false) {
            if ($this->inRv($position)) {
                $this->word = Utf8::substr($this->word, 0, $position);
                return true;
            }
        }
        return false;
    }
1062443
public function hasData()
    {
        return
            $this->countryCode !== ''
            ||
            $this->countryName !== ''
            ||
            $this->stateProvinceCode !== ''
            ||
            $this->stateProvinceName !== ''
            ||
            $this->cityName !== ''
            ||
            $this->postalCode !== ''
            ||
            $this->latitude !== null
            ||
            $this->longitude !== null
        ;
    }
878727
public function isTextValid(string $text): bool
    {
        $parser = new Node_Container_Document();

        if ($this->configData['emoticons']['active']) {
            $parser->add_emoticons($this->configData['emoticons']['path']);
        }

        $this->errorText = '';
        $result = true;
        try {
            $parser->parse($text)
                ->detect_links()
                ->detect_emails();

            if ($this->configData['emoticons']['active']) {
                $parser->detect_emoticons();
            }

            $parser->get_html();

        } catch (\Exception $e) {
            $result = false;
            $this->errorText = $e->getMessage();
        } catch (\Throwable $e) {
            $result = false;
            $this->errorText = $e->getMessage();
        }

        return $result;
    }
824780
public function enviar()
    {
        if ($this->enviado) {
            return false;
        }

        http_response_code($this->estadoHttp);

        // Enviamos cabeceras
        foreach ($this->cabeceras as $cabecera => $valores) {
            foreach ($valores as $valor) {
                header($cabecera . ': ' . $valor, false);
            }
        }

        if (!empty($this->contenido)) {
            echo $this->contenido;
        }

        return $this->enviado = true;
    }
1201649
public function isTranslable()
    {
        if ($this->getPath() === null) {
            $this->detectUrlDetails();
        }

        foreach ($this->config->getExcludedUrls() as $regex) {
            $escapedRegex = Text::escapeForRegex(Text::fullTrim($regex));
            $fullRegex = sprintf('/%s/', $escapedRegex);

            if (preg_match($fullRegex, $this->getPath()) === 1) {
                return false;
            }
        }

        return true;
    }
490642
public function escribirCerrar()
    {
        if (!$this->iniciado) {
            throw new \RuntimeException('La sesión no fue iniciada previamente.');
        }

        if (!$this->adaptador->escribir($this->id, $this->datos)) {
            throw new \RuntimeException('Hubo un error escribiendo la sesión.');
        }

        $this->adaptador->cerrar();
        $this->iniciado = false;

        return true;
    }