original_string: public function purgeIndexes(IndexRebuildEvent $event)
      {
          if (!$event->getPurge()) {
              return;
          }
  
          foreach ($this->searchManager->getIndexNames() as $indexName) {
              $event->getOutput()->writeln('<info>Purging index</info>: ' . $indexName);
              $this->searchManager->purge($indexName);
          }
      }
code: public function purgeIndexes(IndexRebuildEvent $event)
      {
          if (!$event->getPurge()) {
              return;
          }
  
          foreach ($this->searchManager->getIndexNames() as $indexName) {
              $event->getOutput()->writeln('<info>Purging index</info>: ' . $indexName);
              $this->searchManager->purge($indexName);
          }
      }
code_tokens: public function purgeIndexes ( IndexRebuildEvent $ event ) { if ( ! $ event -> getPurge ( ) ) { return ; } foreach ( $ this -> searchManager -> getIndexNames ( ) as $ indexName ) { $ event -> getOutput ( ) -> writeln ( '<info>Purging index</info>: ' . $ indexName ) ; $ this -> searchManager -> purge ( $ indexName ) ; } }
docstring: Purges all indexes, if the purge option is set.
  
  @param IndexRebuildEvent $event
docstring_tokens: Purges all indexes if the purge option is set .