Managing resource types

Resource types are a way to enrich the data published by the Client Publishers:

Resource types are configuration dependent, in order to let project leaders evolve their resource types over time without impacting previous other streams and baselines.

Creating resource types

To create Resource types, go to the Project Administration's "Resource Types" section:

Available namespaces and properties

When creating a query, you might sometimes wonder which property and/or namespaces to use. As of now, we can list the namespaces, but available properties remain a challenge.

As for the namespaces, below are available namespaces:

As for the properties available on a given object, the recommended way is currently to use your browser's "Network" tab.

  1. Navigate to the point where you'll only have 1 click to reach the targeted resource
  2. Open the developer console of your browser, and go to the Network
  3. Add a filter to list only XHR requests
  4. Click on the link to the resource you are interested in
  5. Most of the time, the resource you are interested in should be the first starting with an identifier and immediately followed by "?oslc_config.context="
  6. Click on the corresponding request in the Network tab, which should open the details of this request immediately to the right of this request
  7. In this new section, you should see a tab called either Response or Body, which you should click on

Now you can see the various properties of the object of interest. You may use these properties within your queries.

Not all properties from each tool is published to SECollab. If you know of a property from a given tool that you believe is not published, feel free to get in touch with our Support Team to explain your use case.

Some sample resource type's queries

Here are some real world examples for using queries

Basic samples

When creating a resource type, you need to write a query that fetches relevant resources. Such a query is meant to check if a resource has a given set of properties, or if one of its linked resources has a given set of properties. To access a property, you need to write the namespace prefix and the property name, such as `dcterms:title`. Backquotes are required to express properties. Double quotes (") are used to express strings, and <> are used to express URI.

Collaborative links and resource types are always prefixed with "clm_custom".

Query a DOORS property

Let's say you have created a DOORS attribute called "testId" on your published module.

To determine which of the published resources have that property, you would write:

`doors:testId` != NULL

To determine which of the published resources have that property as well as an object text starting with "TRN-", you would write:

`doors:testId` != NULL AND `doors:objectText` =~ "TRN*"

Query a UML Stereotype

Let's say you have published a Rhapsody model that uses stereotypes.

To list all resources of a given stereotype, you would write

`rhp:appliedStereotypesValues` =~ "*&lt;&lt;FlowProperty&gt;&gt;*"