Click or drag to resize

ItemnewOR Method

Inserts logical node with tag <or> under the parent node, which can be Item or Logical, and returns an Item Object that represents a newly inserted logical node.

Namespace:  Aras.IOM
Assembly:  IOM (in IOM.dll) Version: 14.0.20.39432
Syntax
public Item newOR()

Return Value

Type: Item
Logical "OR" item. Returned item shares dom with this item.
Exceptions
ExceptionCondition
Exception If the instance is neither a single regular item (i.e. item referencing <Item> node) nor a logical item.
ArgumentExceptionthis.node is read-only.
Remarks
Logical item is an item which node references to the "logical" tag, i.e. 'or', 'and' or 'not'. Logical items are used to build request conditions where item's properties serve as condition expressions. User has to use setProperty(...), setPropertyCondition(...) to set condition expressions on logical item (see example below). It's possible to build nested logical request conditions by calling newOR(), newAND() or newNOT() on a logical item.
Examples
...
var myItem = myInnovator.newItem('Foo','get');
var logicalOR = myItem.newOR();
logicalOR.setProperty('foo1','bar1, bar2');
logicalOR.setPropertyCondition('foo1', 'in');
logicalOR.setProperty('foo2','junk');
//The following line of code is optional because 'eq' is the default property condition:
logicalOR.setPropertyCondition('foo2', 'eq');
...
See Also