public function get($attributeCode, array $context = null)
    {
        $attribute = $this->getAttribute($attributeCode);

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

        if ($attribute->isCollection()) {
            return $this->getValuesData($attribute, $context);
        }

        return $this->getValueData($attribute, $context);
    }
public function get($attributeCode, array $context = null)
    {
        $attribute = $this->getAttribute($attributeCode);

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

        if ($attribute->isCollection()) {
            return $this->getValuesData($attribute, $context);
        }

        return $this->getValueData($attribute, $context);
    }
public function get ( $ attributeCode , array $ context = null ) { $ attribute = $ this -> getAttribute ( $ attributeCode ) ; $ getter = 'get' . ucfirst ( $ attributeCode ) ; if ( method_exists ( $ this , $ getter ) ) { return $ this -> $ getter ( $ context ) ; } if ( $ attribute -> isCollection ( ) ) { return $ this -> getValuesData ( $ attribute , $ context ) ; } return $ this -> getValueData ( $ attribute , $ context ) ; }
Used to get values in a simple way

@param string     $attributeCode
@param array|null $context

@throws InvalidValueDataException
@throws MissingAttributeException
@throws ContextException

@return mixed
Used to get values in a simple way