Or (query directive)
From WandoraWiki
(Difference between revisions)
Line 6: | Line 6: | ||
Or(Directive d1,Directive d2,...) | Or(Directive d1,Directive d2,...) | ||
+ | |||
+ | == Examples == | ||
+ | |||
+ | importPackage(org.wandora.query2); | ||
+ | importPackage(org.wandora.topicmap); | ||
+ | new Instances().where( | ||
+ | new Or( | ||
+ | new IsOfType("http://www.wandora.org/core/associationtype"), | ||
+ | new IsOfType("http://www.wandora.org/core/contenttype") | ||
+ | ) | ||
+ | ) | ||
+ | |||
+ | This gets all instances of the input topic that are also instances of either association type or content type. | ||
[[Category:Query directives]] | [[Category:Query directives]] |
Latest revision as of 10:11, 21 August 2009
[edit] Description
Includes rows which satisfy at least one of inner filtering directive.
[edit] Constructor
Or(Directive d1,Directive d2,...)
[edit] Examples
importPackage(org.wandora.query2); importPackage(org.wandora.topicmap); new Instances().where( new Or( new IsOfType("http://www.wandora.org/core/associationtype"), new IsOfType("http://www.wandora.org/core/contenttype") ) )
This gets all instances of the input topic that are also instances of either association type or content type.