Tree Filter

Parent Previous Next

Object Tree Filter

The Object Tree Filter tool is responsible for managing the layout of EnSight part and variable objects into tree structures in the EnSight GUI.  The most obvious example are the sections in the Variables panel. Note that the various variables are placed in groups related to the type of variables encountered.  The Object Tree Filter tool behaves similarly to an email filter. It contains a list of rules that are applied in order. If a variable, part or part loader object match the selection criteria for the rule, the action portion of the rule is applied to that object.  The ordering of the rules matters.  

If you open up the dialog, you will see the list of variable filter rules by default:

The rules are automatically saved between EnSight sessions. Each rule can be active or inactive.  They have a name and the action  is listed in the Details column.  For example, the "vector vars" rule is active, it is applied right after the 'Force Variables' rule and if the object is selected by the rule, the result will be to move a variable (ENS_VAR) to a group named 'Vectors'.  By default, the rules are applied whenever a new variable, part or lpart come into existence. You can force the application of the filters to the current objects by unchecking the 'Auto-apply' box and clicking the 'Apply active filters' button.

The "+" and "-" buttons add a new rule or remove the currently selected rule respectively while the up and down arrow buttons will move the currently selected rule up and down the list.  Selecting the "vector vars" rule and clicking on "Edit filter..." allows the specifics of the filter to be viewed and modified.

The dialog allows the user to change the name of the filter, which is only used for display purposes.  The "Object type" selects the type of EnSight objects the rule applies to.  These can be variables, parts or the part loader objects which are used to conditionally load a part into EnSight. The 'Move to group' option menu selects the specific groupname that the object should be made a child of, if the matching rules below it evaluate to true.  Note: when setting up a new rule, the target group must already exist for it to show up in this list. The group does not have to exist when the rule action is applied.  It will be created automatically if needed.

This leads to the selection criteria.  A number of criteria filters may exist (in the example, only one is used) and the 'Match' rule allows one to specify if all of the criteria must be matched or if a single criteria needs to match for the rule to evaluate to true.  The criteria are applied in order and the "+", "-" and up/down buttons allow for criteria to be added, removed or reordered respectively. Each criteria stanza consists of a specific object attribute, a comparison function and a reference value.  In the example, the "Type" attribute is checked to see if it equals 'Vector'.  If so, the entire rule evaluates to true and the move action it specifies is applied. There are a variety of attributes and specific comparisons that can be tested for.