skip to main content
Corticon Studio: Rule Modeling Guide : Answers to test-yourself questions : Test yourself answers: Collections

Try Corticon Now

Test yourself answers: Collections

Show me this set of test questions.
1. Children of a Parent entity are also known as elements of a collection.
2. False. A collection can contain root-level entities.
3. True
4. True
5. Refer to the Rule Language Guide for a full list and description of all collection operators.
6. Rule Language Guide
7. Order total is equal to the sum of the line item prices on the order.
8. items
9. one-to-many (1->*)
10. It is not an acceptable replacement since the use of any collection operator requires that the collection be represented by an alias.
11. set the navigability of the association between Order and LineItem to Order->lineItem. In other words, make the association one-directional from Order to LineItem.
12. Optional, Convenient
13. A collection alias is not required in this case because no collection operator is being applied to the collection.
14. ->forAll
15. ->exists
a. aroles ->size > 3 where aroles is an alias for Actor.roles
b. mdvd ->isEmpty where mdvd is an alias for Movie.dVD
c. mdextras ->exists(deletedScenes=T) where mdextras is an alias for Movie.dVD.extras
d. mgglobes ->exists(win=T) where mgglobes is an alias for Movie.goldenGlobe
e. mroles ->size > 15 where mroles is an alias for Movie.roles
f. mdvd.quantityAvailable ->sum >= 100 where mdvd is an alias for Movie.dVD
g. mdvd.quantityAvailable ->sum < 2 where mdvd is an alias for Movie.dVD
h. mdsuppliers ->size > 1 where mdsuppliers is an alias for Movie.dVD.supplier
17. Actor, Distributor, DVDExtras
18. Actor, Movie
19. The ->forAll operator tests whether all elements of a collection satisfy a condition. The ->exists operator tests whether at least one element of a collection satisfies a condition.
20. The ->notEmpty operator tests whether a collection is not empty, meaning there is at least one element in the collection. The ->isEmpty operator tests whether a collection is empty, meaning there are no elements in the collection.
21. To ensure that the system knows precisely which collection (or copy) you are referring to in your rules, it’s necessary to use a unique alias to refer to each collection.