setSettings() public method

Can be used to change settings during runtime. One example is to use it for bulk updating.
public setSettings ( array $data ) : Response
$data array Data array
return Response Response object
 /**
  * Stores the settings in the index
  * This is needed for things like tokenizers and analyzers
  * @param array $settings
  */
 protected function applySettings(array $settings)
 {
     $this->index->close();
     sleep(2);
     try {
         $this->index->setSettings($settings);
     } catch (\Exception $e) {
         $this->outputLine($e->getMessage());
     }
     sleep(2);
     $this->index->open();
 }