Skip to content

Usage e.g. for Commands #1

@frauzufall

Description

@frauzufall

Could this be used to pass options to a command / plugin?

E.g.

commandService.run(Threshold.class, true, new ThresholdOptions().setThreshold(0.5));
ioService.open("table.xml", new TableOptions().readLine(true));

For the CommandService, this could be executed by adding

Future<CommandModule> run(String className, boolean process,
        Options options) {
   return run(className, process, options.map());
}

(though options.map() does not exist in the current implementation of the Options interface)

.. We could actually get rid of the process parameter as well this way (in a new iteration of the command service) - with something like:

commandService.run("mycommand", new CommandOptions().runPrePostProcessing(true));

.. or is this stupid because you don't know if the options match the command which is chosen by the CommandService?

@ctrueden @imagejan

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions