Skip to main content
Version: 6.x

View (VIEW)

The view operator creates a property that returns TRUE if the object collection is visible to the user in the specified object group, and NULL otherwise.

Language

To declare a property that determines whether a specified object collection is displayed to the user or not, use the VIEW operator.

Examples

CLASS Store;
name = DATA STRING[100] (Store);

FORM stores
OBJECTS s = Store
;
countF 'Number of filtered warehouses' = GROUP SUM 1 IF [ VIEW stores.s](Store s);
orderF 'Order in an object group' (Store s) = PARTITION SUM 1 IF [ FILTER stores.s](s) ORDER [ ORDER stores.s](s), s;
setNameX 'Add X to name'() {
LOCAL k = INTEGER ();
k() <- 0;
FOR [ FILTER stores.s](Store s) ORDER [ ORDER stores.s](s) DO {
k() <- k() + 1;
name(s) <- 'X' + k() + name(s);
}
}