public function getCost()
 {
     /** If @ref $extras_ is an array, its items are put together
      *	with OR operators, which is typcially slow, therefore one
      *	unit of @ref DpleFeature::getCost() is
      *	accounted for each item. Items in @ref $notExtras_ instead
      *	are put together with AND, which is typically efficient,
      *	and therefore only one unit is accounted for the whole
      *	array, if any. */
     return (count($this->extras_) + (int) (bool) $this->notExtras_) * parent::getCost();
 }
 public function __construct(array $params, array &$features)
 {
     parent::__construct($features);
     $this->order_ = $this->parseOrder(isset($params['order']) ? $params['order'] : null);
     /** The interpretation of the `ordermethod` parameter depends
      * on other features; therefore, this parameter is just stored
      * in @ref $ordermethod_, and invocation of parseOrdermethod()
      * is deferred to modifyQuery(), when all features have been
      * constructed. */
     $this->ordermethod_ = isset($params['ordermethod']) ? $params['ordermethod'] : null;
     $this->sqlOrder_ = $this->order_ == 'descending' ? 'DESC' : 'ASC';
 }
 public function getCost()
 {
     global $wgDpleCondCostMap;
     /** When selecting by `[not]modifiedby`, the record sets
      * selected from the joined tables may be very large, unlike
      * selection by `lastmodifiedby`. Therefore, the cost per
      * condition for this is stored in an extra entry with an
      * "Expensive" appended to the key.
      */
     $highCostKey = get_class($this) . 'Expensive';
     $highCost = isset($wgDpleCondCostMap[$highCostKey]) ? $wgDpleCondCostMap[$highCostKey] : parent::getCost();
     return ((int) (bool) $this->createdby_ + (int) (bool) $this->notCreatedby_ + (int) (bool) $this->lastmodifiedby_ + (int) (bool) $this->notLastmodifiedby_) * parent::getCost() + ((int) (bool) $this->modifiedby_ + (int) (bool) $this->notModifiedby_) * $highCost;
 }
 public function getCost()
 {
     /** If @ref $titleprefixes_, @ref $titlesuffixes_, @ref
      *	$titlecontains_ are arrays, the items in each array are
      *	put together with OR operators, which is typcially slow,
      *	therefore one unit of @ref
      *	DpleFeature::getCost() is accounted for
      *	each item. Items in @ref $notTitleprefixes_ etc. instead
      *	are put together with AND, which is typically efficient,
      *	and therefore only one unit is accounted for each
      *	array. */
     return (count($this->titleprefixes_) + count($this->titlesuffixes_) + count($this->titlecontains_) + (int) (bool) $this->notTitleprefixes_ + (int) (bool) $this->notTitlesuffixes_ + (int) (bool) $this->notTitlecontains_) * parent::getCost();
 }
 public function __construct(array $params, array &$features)
 {
     parent::__construct($features);
     $this->subpages_ = $this->parseIncludeExclude(isset($params['subpages']) ? $params['subpages'] : null);
 }
 public function __construct(array $params, array &$features)
 {
     self::initConf();
     parent::__construct($features);
     $this->count_ = $this->parse(isset($params['count']) ? $params['count'] : null);
 }
 public function __construct(array $params, array &$features)
 {
     /** Call initConf(). */
     self::initConf();
     parent::__construct($features);
 }
 public function __construct(array $params, array &$features)
 {
     parent::__construct($features);
 }
 public function getCost()
 {
     return ($this->linkedCount_ + $this->notLinkedCount_) * parent::getCost();
 }
 public function getCost()
 {
     return isset($this->namespaces_) || isset($this->notNamespaces_) ? parent::getCost() : 0;
 }