12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182 |
- <?php
- namespace Sylius\Component\Translation\Model;
- class AbstractTranslation implements TranslationInterface
- {
-
- protected $locale;
-
- protected $translatable;
-
- public function getTranslatable()
- {
- return $this->translatable;
- }
-
- public function setTranslatable(TranslatableInterface $translatable = null)
- {
- if ($translatable === $this->translatable) {
- return $this;
- }
- $old = $this->translatable;
- $this->translatable = $translatable;
- if (null !== $old) {
- $old->removeTranslation($this);
- }
- if (null !== $translatable) {
- $translatable->addTranslation($this);
- }
- return $this;
- }
-
- public function getLocale()
- {
- return $this->locale;
- }
-
- public function setLocale($locale)
- {
- $this->locale = $locale;
- return $this;
- }
- }
|