Example #1
0
 /**
  * Set the decorated translator
  *
  * @param   KTranslatorInterface $delegate The decorated translator
  * @return  KTranslatorCache
  * @throws  InvalidArgumentException If the delegate does not implement the TranslatorInterface
  */
 public function setDelegate($delegate)
 {
     if (!$delegate instanceof KTranslatorInterface) {
         throw new InvalidArgumentException('Delegate: ' . get_class($delegate) . ' does not implement KTranslatorInterface');
     }
     return parent::setDelegate($delegate);
 }