Skip to main content
Names of elements, constants and variables can be used only in certain sections of a program. This is called the “scope” of the name. The scope of a variable also determines its lifetime. The name of a variable declared in any Code Editor section is accessible only within that particular section, and only after the point of declaration. A name declared within a block is accessible only within that block and the blocks enclosed by it, and only after the point of declaration:
{
 Int a; a = 5;
 }

Accessing Element Hypotheses

Element hypotheses can be accessed through the names of the elements. In both element description sections (Search Conditions and Hypotheses Evaluation) you can access the hypotheses for all elements located above the current element in the same hypothesis tree branch. Moreover, the formulated hypothesis for an element may be called in the Hypotheses Evaluation section for that element. Code from the Search Conditions section is executed separately for each hypothesis independently of the hypotheses which are located on other branches of the tree of hypotheses. This means that when the program executes the code of a particular section of an element description, it can access only one hypothesis for each superordinate element, namely the hypothesis which is located on the same branch. Element hypotheses and their properties are accessed in read-only mode.

Element Naming

Hypotheses for a superordinate element are called by the full name of the element, for example: SearchObjects.Group1.Group2.FirstItem. When accessing one subelement of a group from another subelement, you need not specify the name of the group. For example, in the Advanced sections of the element SearchObjects.Group1.Group2.SecondItem, you can call the element SearchObjects.Group1.Group2.FirstItem in one of the following ways: SearchObjects.Group1.Group2.FirstItem, Group1.Group2.FirstItem, Group2.FirstItem, FirstItem. The shortcut name will always refer to the most nested element. Suppose we have the following tree of elements:
SearchElements
 FirstItem
 Group1
 FirstItem
 SecondItem
If you are in SearchElements.Group1.SecondItem and use the name FirstItem, you will call the SearchElements.Group1.FirstItem element, and not the SearchElements.FirstItem element.