protected function getPropertyValue($propertyName)
    {
        $desiredKey = $this->trimPrefixKey($propertyName);

        $getter = 'get' . ucfirst($this->getPropertyName($desiredKey));
        if (method_exists($this, $getter)) {
            return $this->$getter();
        }

        // Otherwise, try to get sub object to get data
        $subKey = strtolower(strstr($desiredKey, '_', true));
        $getterMethodName = 'get' . ucfirst($subKey);

        $subObject = $this->$getterMethodName();
        if ($subObject instanceof EntityAbstract) {
            return $subObject->getPropertyValue($desiredKey);
        }

        throw new \InvalidArgumentException(
            sprintf(
                'No getter set for %s (getter was %s:%s)',
                $propertyName,
                get_called_class(),
                $getter
            )
        );
    }
protected function getPropertyValue($propertyName)
    {
        $desiredKey = $this->trimPrefixKey($propertyName);

        $getter = 'get' . ucfirst($this->getPropertyName($desiredKey));
        if (method_exists($this, $getter)) {
            return $this->$getter();
        }

        // Otherwise, try to get sub object to get data
        $subKey = strtolower(strstr($desiredKey, '_', true));
        $getterMethodName = 'get' . ucfirst($subKey);

        $subObject = $this->$getterMethodName();
        if ($subObject instanceof EntityAbstract) {
            return $subObject->getPropertyValue($desiredKey);
        }

        throw new \InvalidArgumentException(
            sprintf(
                'No getter set for %s (getter was %s:%s)',
                $propertyName,
                get_called_class(),
                $getter
            )
        );
    }
protected function getPropertyValue ( $ propertyName ) { $ desiredKey = $ this -> trimPrefixKey ( $ propertyName ) ; $ getter = 'get' . ucfirst ( $ this -> getPropertyName ( $ desiredKey ) ) ; if ( method_exists ( $ this , $ getter ) ) { return $ this -> $ getter ( ) ; } // Otherwise, try to get sub object to get data $ subKey = strtolower ( strstr ( $ desiredKey , '_' , true ) ) ; $ getterMethodName = 'get' . ucfirst ( $ subKey ) ; $ subObject = $ this -> $ getterMethodName ( ) ; if ( $ subObject instanceof EntityAbstract ) { return $ subObject -> getPropertyValue ( $ desiredKey ) ; } throw new \ InvalidArgumentException ( sprintf ( 'No getter set for %s (getter was %s:%s)' , $ propertyName , get_called_class ( ) , $ getter ) ) ; }
Get method name for getter

@param  string $propertyName
@throws \InvalidArgumentException
@return string
Get method name for getter