src/GameOfLife/OptionHandler/OptionLoader.php
/**
     * Adds the default options to the option list.
     *
     * @param Getopt $_options The option list
     */
Adds the default options to the option list.
@param Getopt $_options The option list
Adds the default options to the option list . @param Getopt $_options The option list
public function addDefaultOptions(Getopt $_options)
    {
        $_options->addOptions(
            array(
                array(null, "width", Getopt::REQUIRED_ARGUMENT, "Set the board width (Default: 20)"),
                array(null, "height", Getopt::REQUIRED_ARGUMENT, "Set the board height (Default: 10)"),
                array(null, "maxSteps", Getopt::REQUIRED_ARGUMENT, "Set the maximum amount of steps that are calculated before the simulation stops (Default: 50)"),
                array(null, "border", Getopt::REQUIRED_ARGUMENT, "Set the border type (solid|passthrough) (Default: solid)"),
                array(null, "input", Getopt::REQUIRED_ARGUMENT, "Fill the board with cells (valid arguments: Blinker, Glider, Random, Spaceship)"),
                array(null, "output", Getopt::REQUIRED_ARGUMENT, "Set the output type (valid arguments: console, png)"),
                array(null, "rules", Getopt::REQUIRED_ARGUMENT, "Set the rules for the simulation (valid arguments: Conway, Copy, Two45) (Default: Conway)"),
                array(null, "antiRules", Getopt::NO_ARGUMENT, "Converts the selected rules to anti rules"),
                array(null, "version", Getopt::NO_ARGUMENT, "Print script version"),
                array("h", "help", Getopt::NO_ARGUMENT, "Show this help screen\n")
            )
        );
    }
public function addDefaultOptions ( Getopt $ _options ) { $ _options -> addOptions ( array ( array ( null , " width " , Getopt :: REQUIRED_ARGUMENT , " Set the board width (Default: 20) " ) , array ( null , " height " , Getopt :: REQUIRED_ARGUMENT , " Set the board height (Default: 10) " ) , array ( null , " maxSteps " , Getopt :: REQUIRED_ARGUMENT , " Set the maximum amount of steps that are calculated before the simulation stops (Default: 50) " ) , array ( null , " border " , Getopt :: REQUIRED_ARGUMENT , " Set the border type (solid|passthrough) (Default: solid) " ) , array ( null , " input " , Getopt :: REQUIRED_ARGUMENT , " Fill the board with cells (valid arguments: Blinker, Glider, Random, Spaceship) " ) , array ( null , " output " , Getopt :: REQUIRED_ARGUMENT , " Set the output type (valid arguments: console, png) " ) , array ( null , " rules " , Getopt :: REQUIRED_ARGUMENT , " Set the rules for the simulation (valid arguments: Conway, Copy, Two45) (Default: Conway) " ) , array ( null , " antiRules " , Getopt :: NO_ARGUMENT , " Converts the selected rules to anti rules " ) , array ( null , " version " , Getopt :: NO_ARGUMENT , " Print script version " ) , array ( " h " , " help " , Getopt :: NO_ARGUMENT , " Show this help screen \n " ) ) ) ; }
Adds the default options to the option list.
Adds the default options to the option list .
// board options // other options