Skip to content

Service descriptors defining the difference between a required parameter and an optional parameter #51

@robyww

Description

@robyww

When a service descriptor defines a parameter there seems to be no way to know if the parameter is require or if it is optional. This is important for a UI that reads the service descriptor and provides the user a way input those parameters.

This is not a suggestion of syntax, but just an illustration of a solution. I added an isOptional in the third parameter below.

  <RESOURCE type="meta" utype="adhoc:service">
    <DESCRIPTION>a service</DESCRIPTION>
    <GROUP name="inputParams">
      <PARAM name="abc" datatype="char" arraysize="*" ref="col_0" value="">
        <DESCRIPTION>a ref param</DESCRIPTION>
      </PARAM>
      <PARAM name="efg" datatype="char" arraysize="*"  value="123">
        <DESCRIPTION>a required param</DESCRIPTION>
      </PARAM>
      <PARAM name="mn" datatype="char" arraysize="*"  value=""  isOptional="true">
        <DESCRIPTION>a optional param</DESCRIPTION>
      </PARAM>
    </GROUP>
    <PARAM name="accessURL" datatype="char" arraysize="*" value="http://a.b.com/aEndpoint"/>
  </RESOURCE>

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions