src/EntityUtils.php
public static function extractValueFromEntity($entity, $property)
    {
        $getter = self::createGetter($entity, $property);

        return $entity->$getter();
    }
public static function extractValueFromEntity($entity, $property)
    {
        $getter = self::createGetter($entity, $property);

        return $entity->$getter();
    }
public static function extractValueFromEntity ( $ entity , $ property ) { $ getter = self :: createGetter ( $ entity , $ property ) ; return $ entity -> $ getter ( ) ; }
Extract the value of a property from an entity.

@param mixed  $entity
@param string $property

@throws \InvalidArgumentException

@return mixed
Extract the value of a property from an entity .