private function getFieldValue($object, Field $field)
    {
        if (is_array($object)) {
            $path = '[' . $field->getName() . ']';
        } else {
            $path = $field->getName();
        }

        return $this->accessor->getValue($object, $path);
    }
private function getFieldValue($object, Field $field)
    {
        if (is_array($object)) {
            $path = '[' . $field->getName() . ']';
        } else {
            $path = $field->getName();
        }

        return $this->accessor->getValue($object, $path);
    }
private function getFieldValue ( $ object , Field $ field ) { if ( is_array ( $ object ) ) { $ path = '[' . $ field -> getName ( ) . ']' ; } else { $ path = $ field -> getName ( ) ; } return $ this -> accessor -> getValue ( $ object , $ path ) ; }
Return a value determined from the name of the field
rather than an explicit property.

If the object is an array, then force the array syntax.

@param mixed $object
@param Field $field
Return a value determined from the name of the field rather than an explicit property .