<commit_before><?php declare(strict_types = 1);
namespace TheSeer\Templado;

class FileName {

    private $path;

    /**
     * FileName constructor.
     *
     * @param $path
     */
    public function __construct(string $path) {
        $this->path = $path;
    }

    /**
     * @return string
     */
    public function asString(): string {
        return $this->path;
    }

}<commit_msg>Add helpers to FileName<commit_after><?php declare(strict_types = 1);
namespace TheSeer\Templado;

class FileName {

    /**
     * @var string
     */
    private $path;

    /**
     * FileName constructor.
     *
     * @param $path
     */
    public function __construct(string $path) {
        $this->path = $path;
    }

    /**
     * @return string
     */
    public function asString(): string {
        return $this->path;
    }

    /**
     * @return bool
     */
    public function exists(): bool {
        return file_exists($this->path);
    }

    /**
     * @return bool
     */
    public function isFile(): bool {
        return is_file(realpath($this->path));
    }

    /**
     * @return bool
     */
    public function isReadable(): bool {
        return is_readable($this->path);
    }

}
{'fraction_non_alphanumeric': 0.13920922570016475, 'fraction_numerical': 0.0016474464579901153, 'mean_word_length': 1.865566037735849, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 10, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6463870', 'n_tokens_mistral': 382, 'n_tokens_neox': 370, 'n_words': 83}