public function computed(callable $computedPropertyCallback): GetterSetterColumnDefiner
    {
        return new GetterSetterColumnDefiner($this, function (Column $column) use ($computedPropertyCallback) {
            $this->columnGetterMap[$column->getName()] = $computedPropertyCallback;
            $this->addColumn($column);
        });
    }
public function computed(callable $computedPropertyCallback): GetterSetterColumnDefiner
    {
        return new GetterSetterColumnDefiner($this, function (Column $column) use ($computedPropertyCallback) {
            $this->columnGetterMap[$column->getName()] = $computedPropertyCallback;
            $this->addColumn($column);
        });
    }
public function computed ( callable $ computedPropertyCallback ) : GetterSetterColumnDefiner { return new GetterSetterColumnDefiner ( $ this , function ( Column $ column ) use ( $ computedPropertyCallback ) { $ this -> columnGetterMap [ $ column -> getName ( ) ] = $ computedPropertyCallback ; $ this -> addColumn ( $ column ) ; } ) ; }
Defines a mapping between the results of a computed property
to a column.

Example:
<code>
->computed(function ($entity) {
return $entity->getData();
})
->to('column_name')->asInt();
</code>

@param callable $computedPropertyCallback

@return GetterSetterColumnDefiner
Defines a mapping between the results of a computed property to a column .