Format for boolean data type specified in Metadata consists of up to four parts separated from each other by the same delimiter.
This delimiter must also be at the beginning and the end of the Format string. On the other hand, the delimiter must not be contained in the values of the boolean field.
Important | |
---|---|
If you do not use the same character at the beginning and the end of the Format string,
the whole string will serve as the regular expression for the Values that match neither the Format regular expression (interpreted as |
If we symbolically display the format as:
/A/B/C/D/
th meaning of each part is as follows:
If the value of the boolean field matches the pattern of the first part (A
)
and does not match the second part (B
), it is interpreted as true
.
If the value of the boolean field does not match the pattern of the first part (A
), but
matches the second part (B
), it is interpreted as false
.
If the value of the boolean field matches both the pattern of the first part (A
) and, at the same time,
the pattern of the second part (B
), it is interpreted as true
.
If the value of the boolean field matches neither the pattern of the first part (A
), nor
the pattern of the second part (B
), it is interpreted as error. In such a case, the graph would fail.
All parts are optional, however, if any of them is omitted, all of the others that are at its right side must also be omitted.
If the second part (B
) is omitted, the following default values are the only ones that are parsed as boolean false
:
false|F|FALSE|NO|N|f|0|no|n
If there is not any Format, the following default values are the only ones that are parsed as boolean true
:
true|T|TRUE|YES|Y|t|1|yes|y
The third part (C
) is a formatting string used to
express boolean true
for all matched strings.
If the third part is omitted, either the true
word is used
(if the first part (A
) is complicated regular expression), or the first substring from the first part is used
(if the first part is a serie of simple substrings separated by pipe, e.g.: Iagree|sure|yes|ok
- all these values would be formatted as Iagree
).
The fourth part (D
) is a formatting string used to
express boolean false
for all matched strings.
If the fourth part is omitted, either the false
word is used
(if the second part (B
) is complicated regular expression), or the first substring from the second part is used
(if the second part is a serie of simple substrings separated by pipe, e.g.: Idisagree|nope|no
- all these values would be formatted as Idisagree
).