original_string: public function getCriteriaForListModule(array $archives, $featured, Module $module)
      {
          $criteria = new NewsCriteria($this->framework);
  
          try {
              $criteria->setBasicCriteria($archives, $module->news_order);
  
              // Set the featured filter
              if (null !== $featured) {
                  $criteria->setFeatured($featured);
              }
  
              // Set the criteria for related categories
              if ($module->news_relatedCategories) {
                  $this->setRelatedListCriteria($criteria, $module);
              } else {
                  // Set the regular list criteria
                  $this->setRegularListCriteria($criteria, $module);
              }
          } catch (NoNewsException $e) {
              return null;
          }
  
          return $criteria;
      }
code: public function getCriteriaForListModule(array $archives, $featured, Module $module)
      {
          $criteria = new NewsCriteria($this->framework);
  
          try {
              $criteria->setBasicCriteria($archives, $module->news_order);
  
              // Set the featured filter
              if (null !== $featured) {
                  $criteria->setFeatured($featured);
              }
  
              // Set the criteria for related categories
              if ($module->news_relatedCategories) {
                  $this->setRelatedListCriteria($criteria, $module);
              } else {
                  // Set the regular list criteria
                  $this->setRegularListCriteria($criteria, $module);
              }
          } catch (NoNewsException $e) {
              return null;
          }
  
          return $criteria;
      }
code_tokens: public function getCriteriaForListModule ( array $ archives , $ featured , Module $ module ) { $ criteria = new NewsCriteria ( $ this -> framework ) ; try { $ criteria -> setBasicCriteria ( $ archives , $ module -> news_order ) ; // Set the featured filter if ( null !== $ featured ) { $ criteria -> setFeatured ( $ featured ) ; } // Set the criteria for related categories if ( $ module -> news_relatedCategories ) { $ this -> setRelatedListCriteria ( $ criteria , $ module ) ; } else { // Set the regular list criteria $ this -> setRegularListCriteria ( $ criteria , $ module ) ; } } catch ( NoNewsException $ e ) { return null ; } return $ criteria ; }
docstring: Get the criteria for list module.
  
  @param array     $archives
  @param bool|null $featured
  @param Module    $module
  
  @return NewsCriteria|null
docstring_tokens: Get the criteria for list module .