protected function getDataValue($data, $field)
    {
        if (!isset($this->dataNamesMap[$field]['get'])) {
            throw new \DomainException('Field have not mapping with Data instance (field: ' . $field . ')');
        }

        $method = $this->dataNamesMap[$field]['get'];

        return $data->{$method}();
    }
protected function getDataValue($data, $field)
    {
        if (!isset($this->dataNamesMap[$field]['get'])) {
            throw new \DomainException('Field have not mapping with Data instance (field: ' . $field . ')');
        }

        $method = $this->dataNamesMap[$field]['get'];

        return $data->{$method}();
    }
protected function getDataValue ( $ data , $ field ) { if ( ! isset ( $ this -> dataNamesMap [ $ field ] [ 'get' ] ) ) { throw new \ DomainException ( 'Field have not mapping with Data instance (field: ' . $ field . ')' ) ; } $ method = $ this -> dataNamesMap [ $ field ] [ 'get' ] ; return $ data -> { $ method } ( ) ; }
Get value from DataAbstract instance based on field value

@param  DataAbstract $data
@param  string       $field
@return mixed
@throws \DomainException
Get value from DataAbstract instance based on field value