setOptions() public méthode

Any existing options are removed when this method is called.
See also: addOption()
public setOptions ( array $options ) : static
$options array The options of the built format.
Résultat static The current instance.
 public function testSetOptions()
 {
     $this->builder->addOption($option1 = new Option('option1'));
     $this->builder->setOptions(array($option2 = new Option('option2'), $option3 = new Option('option3')));
     $this->assertSame(array('option2' => $option2, 'option3' => $option3), $this->builder->getOptions());
 }