private function refreshGeneratedFieldValues($id)
    {
        $result = [];

        if (!empty($this->generated_fields)) {
            $result = $this->connection->selectFirstRow($this->getTableName(), $this->generated_fields, $this->getWherePartById($id));

            if (empty($result)) {
                $result = [];
            }
        }

        $value_caster = $this->getGeneratedFieldsValueCaster();

        if ($value_caster instanceof ValueCasterInterface) {
            $value_caster->castRowValues($result);
        }

        return $result;
    }
private function refreshGeneratedFieldValues($id)
    {
        $result = [];

        if (!empty($this->generated_fields)) {
            $result = $this->connection->selectFirstRow($this->getTableName(), $this->generated_fields, $this->getWherePartById($id));

            if (empty($result)) {
                $result = [];
            }
        }

        $value_caster = $this->getGeneratedFieldsValueCaster();

        if ($value_caster instanceof ValueCasterInterface) {
            $value_caster->castRowValues($result);
        }

        return $result;
    }
private function refreshGeneratedFieldValues ( $ id ) { $ result = [ ] ; if ( ! empty ( $ this -> generated_fields ) ) { $ result = $ this -> connection -> selectFirstRow ( $ this -> getTableName ( ) , $ this -> generated_fields , $ this -> getWherePartById ( $ id ) ) ; if ( empty ( $ result ) ) { $ result = [ ] ; } } $ value_caster = $ this -> getGeneratedFieldsValueCaster ( ) ; if ( $ value_caster instanceof ValueCasterInterface ) { $ value_caster -> castRowValues ( $ result ) ; } return $ result ; }
Return an array with potentially refreshed values of generated fields.

@param  int   $id
@return array
Return an array with potentially refreshed values of generated fields .