[go: up one dir, main page]

Improve simulator configuration file when multiple identical environments can be declared

Currently, if ten identical environments need to be declared in the simulator configuration file, it is necessary to repeat ten times the same information, varying only the environment ID.

Make it possible to declare repeated environments.

Something like this:

{
    "run_as_simulator" : true,
    "user_defined_base_module" : "arps.test_resources.dummies",
    "environments" : [
	{ "identifier" : [0,1,2],
    ...
        { "identifier" : [4,5,6,7,8],
    ....

The file above should be used to declare 8 environments of two different types. I prefer to have as a list to make explicit instead of an implicit way using an interval, like [0,2] and [4,8], to avoid consistency checking other than verify if the id is repeated.

The old way to declare should be supported. The distinction is in the type of the identifier attribute. If it's a list process as multiple environments. If it's an integer, process as a single environment.

Edited by arps