Interface CLOProvider

All Known Implementing Classes:
Advection, ATBT, ATBT.ODE, CDL, CDLP, CDLPQ, Centipede, CLabour, Continuous, CSD, DemesTBT, Discrete, EcoPGG, EvoLudo, EvoLudoGWT, EvoLudoWeb, IBS, IBSC, IBSD, Model, Module, Moran, NetGames, ODE, PDE, RSP, RungeKutta, scanCSD, SDE, simCDL, simCDLP, simCDLPQ, simMoran, simTBT, simTraits, TBT, Traits

public interface CLOProvider
Interface for classes that that to provide command line options for configurable parameters.
Author:
Christoph Hauert
  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    Providers of command line options may want to remove certain options that other providers provided by overriding this method.
    void
    All providers of command line options must implement this method to collect their options.
  • Method Details

    • collectCLO

      void collectCLO(CLOParser parser)
      All providers of command line options must implement this method to collect their options.

      Each command line option is (uniquely) identified by it's name (see CLOption.getName()), which corresponds to the long version of the option. If an attempt is made to add an option with a name that already exists, the parser issues a warning and ignores the option. Thus, in general, implementing subclasses should first register their options and call super.collectCLO(CLOParser) at the end such that subclasses are able to override command line options specified in a parental class.

      Override this method in subclasses to add further command line options. Subclasses must make sure that they include a call to super.

      Parameters:
      parser - the reference to parser that manages command line options
      See Also:
    • adjustCLO

      default void adjustCLO(CLOParser parser)
      Providers of command line options may want to remove certain options that other providers provided by overriding this method. After all command line options are collected, all providers get a chance to adjust the collection. In particular, options should be removed that do not make sense in present context. Overriding methods usually call CLOParser.removeCLO(String[]) or variants thereof.
      Parameters:
      parser - the reference to parser that manages command line options
      See Also: