Eloquent\Dialect\Json::hintJsonStructure PHP Метод

hintJsonStructure() публичный Метод

Sets a hint for a given column.
public hintJsonStructure ( string $column, string $structure )
$column string name of column that we're hinting
$structure string json encoded structure
    public function hintJsonStructure($column, $structure)
    {
        if (json_decode($structure) === null) {
            throw new InvalidJsonException();
        }
        $this->hintedJsonAttributes[$column] = $structure;
        // Run the call to add hinted attributes to the internal json
        // attributes array. This allows callers to get/set parameters when
        // working with new models
        $this->addHintedAttributes();
    }