code: public function setRuleType($pRuleType)
      {
          if (!in_array($pRuleType, self::$ruleTypes)) {
              throw new PhpSpreadsheetException('Invalid rule type for column AutoFilter Rule.');
          }
  
          $this->ruleType = $pRuleType;
  
          return $this;
      }
docs: Set AutoFilter Rule Type.
  
  @param string $pRuleType see self::AUTOFILTER_RULETYPE_*
  
  @throws PhpSpreadsheetException
  
  @return Rule