src/Sulu/Bundle/CategoryBundle/Api/Category.php
private function getTranslation($withDefault = false)
    {
        $translation = $this->getTranslationByLocale($this->locale);

        if (true === $withDefault && null === $translation && null !== $this->getDefaultLocale()) {
            return $this->getTranslationByLocale($this->getDefaultLocale());
        }

        return $translation;
    }
private function getTranslation($withDefault = false)
    {
        $translation = $this->getTranslationByLocale($this->locale);

        if (true === $withDefault && null === $translation && null !== $this->getDefaultLocale()) {
            return $this->getTranslationByLocale($this->getDefaultLocale());
        }

        return $translation;
    }
private function getTranslation ( $ withDefault = false ) { $ translation = $ this -> getTranslationByLocale ( $ this -> locale ) ; if ( true === $ withDefault && null === $ translation && null !== $ this -> getDefaultLocale ( ) ) { return $ this -> getTranslationByLocale ( $ this -> getDefaultLocale ( ) ) ; } return $ translation ; }
Returns the translation with the current locale.

@param $withDefault

@return CategoryTranslationInterface
Returns the translation with the current locale .