On 27/11/13 19:57, Jay Pipes wrote:

Actually, even simpler than that...

parameters:
   db:
    - db_name:
      description: blah
      help: blah
    - db_username:
      description: blah
      help: blah

After all, can't we assume that if the parameter value is a list, then
it is a group of parameters?

This resolves to a fairly weird construct:

{
  "parameters": {
    "db": [
      {
        "db_name": null,
        "description": "blah",
        "help": "blah"
      },
      {
        "description": "blah",
        "db_username": null,
        "help": "blah"
      }
    ]
  }
}

so the name is whichever key has a data value of null (what if there's more than one?), and obviously it can't collide with any keywords like "description" or "help".

Also, this orders parameters within a group (though not parameters that are ungrouped) but not the groups themselves.

cheers,
Zane.

_______________________________________________
OpenStack-dev mailing list
OpenStack-dev@lists.openstack.org
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev

Reply via email to