It's all about the answers!

Ask a question

Is there more documentation for RelationshipRange?


Troy Klomp (858) | asked Aug 07 '14, 10:11 a.m.
The only documentation that I can find on relationship ranges is the API class RelationshipRange. Here is an excerpt from this......

com.ibm.ram.common.data
Class RelationshipRange

java.lang.Object
  extended by com.ibm.ram.common.data.RelationshipRange

public class RelationshipRange
extends java.lang.Object

This is the older way. Use RelationshipRangeUtility functions for newer uses (7.5.1 and later).

Contains information about the relationship version rules. Relationship version rules can be specified on a given relationship between two assets.

 Two types of relationship version rules can be specified:
 a) Highest Version Rule: The asset relationship is maintained to the highest version of the 
          related asset in the range boundary specified.
 b) All Versions Rule: The asset relationship is maintained to all the versions of the
          related asset in the range boundary specified
 
 You can set relationship version rule types by calling the setType(String) method.
 Two possible values can be passed to the set types:
 a) HIGHEST_VERSION
 b) ALL_VERSIONS
 
 You can specify the range boundary by setting the following properties:
 a) Lowest Version: Specify the lowest version of the range by calling setLowestVersion().
 b) Lowest Version Type: Specify the type of the lowest version by calling setLowestVersionType(). 
          The two possible types are GREATER_THAN and GREATER_THAN_OR_EQUAL_TO. 
 c) Highest Version: Specify the highest version of the range by calling setHighestVersion().
 d) Highest Version Type: Specify the type of the highest version by calling setHighestVersionType().
          The two possible types are LESS_THAN and LESS_THAN_OR_EQUAL_TO.
 

Since:
7.1.1


Question 1:  This documentation states at the beginning that "This is the older way. Use RelationshipRangeUtility functions for newer uses (7.5.1 and later)."  What does this statement mean? Is this class still supported? Where can I find documentation for RelationshipRangeUtility? Is this a Java API, or a command-line utility, or something else?


Question 2:  I figured out that via the web browser, we can add a relationship to a selected asset. Then, we are able to Edit the relationship to specify the different range settings. Also, I see the documentation above for using the Java API to set relationship ranges. Is there any command-line capability for setting relationship ranges, or do we need to create our own tool around this? When specifying relationships in the package.json file when using the command-line "ram publish" to create a new asset, is there any way to specify ranges?


Thank you.

   - Troy




One answer



permanent link
Bryan Song (761) | answered Aug 07 '14, 11:00 p.m.
JAZZ DEVELOPER
 Hi Troy,

You could only specify "Depend On" relationship when using RAM command-line, and this dependency should be specified in package.json file.

Bryan

Your answer


Register or 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.