<commit_before><?php

namespace rsanchez\Deep\Col;

use rsanchez\Deep\Fieldtype\Fieldtype;
use rsanchez\Deep\Property\AbstractProperty;
use stdClass;

class Col extends AbstractProperty
{
    // exp_matrix_cols
    public $col_id;
    public $col_name;
    public $col_label;
    public $col_instructions;
    public $col_type;
    public $col_required;
    public $col_search;
    public $col_order;
    public $col_width;
    public $col_settings;

    public function __construct(stdClass $row, Fieldtype $fieldtype)
    {
        parent::__construct($row, $fieldtype);

        if ($this->col_settings) {
            $this->col_settings = unserialize(base64_decode($this->col_settings));
        } else {
            $this->col_settings = array();
        }

        if ($this->has_global_settings === 'y') {
            $this->col_settings = array_merge($this->fieldtype->settings, $this->col_settings);
        }
    }

    public function inputName()
    {
        return $this->prefix() . $this->id();
    }
<commit_msg>Add field_id property to Col, fix typo in Col<commit_after><?php

namespace rsanchez\Deep\Col;

use rsanchez\Deep\Fieldtype\Fieldtype;
use rsanchez\Deep\Property\AbstractProperty;
use stdClass;

class Col extends AbstractProperty
{
    // exp_matrix_cols / exp_grid_columns
    public $col_id;
    public $col_name;
    public $col_label;
    public $col_instructions;
    public $col_type;
    public $col_required;
    public $col_search;
    public $col_order;
    public $col_width;
    public $col_settings;
    public $field_id;

    public function __construct(stdClass $row, Fieldtype $fieldtype)
    {
        parent::__construct($row, $fieldtype);

        if ($this->col_settings) {
            $this->col_settings = unserialize(base64_decode($this->col_settings));
        } else {
            $this->col_settings = array();
        }

        if ($this->fieldtype->has_global_settings === 'y') {
            $this->col_settings = array_merge($this->fieldtype->settings, $this->col_settings);
        }
    }

    public function inputName()
    {
        return $this->prefix() . $this->id();
    }

{'fraction_non_alphanumeric': 0.12149532710280374, 'fraction_numerical': 0.001869158878504673, 'mean_word_length': 2.871609403254973, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 26, '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': '4576824', 'n_tokens_mistral': 670, 'n_tokens_neox': 655, 'n_words': 133}