Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

How can I get allowed values for an RTC enumeration list attribute using web APIs

Hello,
I have an 'Enumeration list' (multiple selection) field, but I cannot get the enumeration values for it.

When I get the resource shape, the field looks like:

<rdf:Description rdf:about="https://my.rtc:9443/ccm/oslc/context/_0u1_QV7hEeSPi_AaoZ4IKA/shapes/workitems/task/property/customMultiSelect">
        <rdf:type rdf:resource="http://open-services.net/ns/core#Property"/>
        <oslc:valueType rdf:resource="http://open-services.net/ns/core#Resource"/>
        <oslc:representation rdf:resource="http://open-services.net/ns/core#Either"/>
        <oslc:readOnly rdf:datatype="http://www.w3.org/2001/XMLSchema#boolean">false</oslc:readOnly>
        <oslc:propertyDefinition rdf:resource="http://jazz.net/xmlns/prod/jazz/rtc/ext/1.0/customMultiSelect"/>
        <oslc:occurs rdf:resource="http://open-services.net/ns/core#Zero-or-many"/>
        <oslc:name rdf:datatype="http://www.w3.org/2001/XMLSchema#string">customMultiSelect</oslc:name>
        <oslc:defaultValue>[]</oslc:defaultValue>
        <dcterms:title rdf:parseType="Literal">Custom Multi Select</dcterms:title>
</rdf:Description>

Enumeration fields (single selection) also have an <oslc:allowedValues> element, that provides an enumeration that can be looked up, but enumeration lists don't seem to have this.

If I retrieve a work item, the field doesn't show up unless it has a value set, so I can't get the possible enumerations from that either. 

How can I get the options for my attribute?

Thanks.

0 votes



One answer

Permanent link

You can get the full definition of the enumerated values using GET on the property definition. There you can get the full mapping between the numerical values (rdf:value) and the string labels (rdfs:label).

0 votes

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 516
× 480

Question asked: Feb 23 '15, 6:32 p.m.

Question was seen: 4,452 times

Last updated: Feb 10 '17, 6:44 a.m.

Confirmation Cancel Confirm