<rule> tag
The <rule> tag defines a global rule.
The attributes of the <rule> tag for screen customization-level
rules are the same as for project-level global rules. However, when
you create a screen customization-level and a project-level global
rule using the same input field, the screen customization-level rule
will have a higher priority. The <rule> tag attributes are:
- associatedScreen
- The name of a screen capture in the project, from which the global rule is defined.
- componentSettings
- Any settings configured for the global rule, such as recognition criteria.
- description
- The description entered when the global rule was created.
- enabled
- Indicates whether this global rule is enabled. Reflects the state of the check box on the Rendering page of Project Settings.
- endCol
- The last column of the host screen to which this global rule should be applied. -1 means the rightmost column of the host screen.
- endRow
- The last row of the host screen to which this global rule should be applied. -1 means the bottom row of the host screen.
- name
- The name that will be shown in the list of global rules on the Rendering page of Project Settings.
- startCol
- The first column of the host screen to which this global rule should be applied.
- startRow
- The first row of the host screen to which this global rule should be applied.
- transformationFragment
- The name of the transformation fragment file associated with this global rule. This file contains the information specifying how to transform the host component. It will be included in a transformation if the appropriate input fields are present in the host screen.
- type
- The pattern type component for this global rule, taken from
the first page of the Create Global Rule wizard. The type can be one
of the following:
- com.ibm.hats.transform.components.InputFieldByTextPatternComponent
- This pattern component recognizes input fields on the host screen based on text near the fields.
- com.ibm.hats.transform.components.AllInputFieldsPatternComponent
- This pattern component recognizes all input fields on the host screen.
- com.ibm.hats.transform.components.InputFieldBySizePatternComponent
- This pattern component recognizes input fields on the host screen based on the size of the input fields.
The following tags are also included in each specific global rule:
- componentSettings
- The <componentSettings> tag is the enclosing tag for any settings defined for the pattern type component specified on the type attribute of the <rule> tag. This tag has no attributes.
- setting
- The <setting> tag is the enclosing tag for any settings defined
for the pattern type component specified on the type attribute of
the <rule> tag.
The attributes of the <setting> tag are:
- name
- Specifies the name of a customizable setting for the pattern
type component. The available settings depend on the component.
- For the com.ibm.hats.transform.components.InputFieldByTextPattern
Component, the settings for the name attribute are:
- caseSensitive
- Specifies whether the case of the text on the text setting must match before the pattern is recognized. Valid values are true and false. The default is true.
- immediatelyNextTo
- Specifies which input fields you want to transform.Valid values are:
- true
- Specifies that only the nearest input field should be transformed.
- false
- Specifies that all input fields should be transformed.
- location
- Specifies where text in a protected field, as specified on the
text setting, must be in relation to input fields for this global
rule to be applied. Valid
values are:
- ABOVE
- Specifies that the text must be above the input field.
- BELOW
- Specifies that the text must be below the input field.
- LEFT
- Specifies that the text must be to the left of the input field.
- RIGHT
- Specifies that the text must be to the right of the input field.
- text
- Specifies some text in a protected field of the host screen. Valid values are any text in a protected field on the host screen.
- For the com.ibm.hats.transform.components.AllInputFieldsPattern Component, there are no component settings.
- For the com.ibm.hats.transform.components. InputFieldBySizePattern Component, the setting for the name attribute is fieldSize.Valid values are the sizes of any input fields on the host screen.
- For the com.ibm.hats.transform.components.InputFieldByTextPattern
Component, the settings for the name attribute are: