示例#1
0
 /**
  * @param IContextSource|Skin $obj
  * @throws MWException
  */
 public function __construct($obj)
 {
     if ($obj instanceof Skin) {
         // @todo: deprecate constructing with Skin
         $context = $obj->getContext();
     } else {
         if (!$obj instanceof IContextSource) {
             throw new MWException('EnhancedChangesList must be constructed with a ' . 'context source or skin.');
         }
         $context = $obj;
     }
     parent::__construct($context);
     // message is set by the parent ChangesList class
     $this->cacheEntryFactory = new RCCacheEntryFactory($context, $this->message);
 }