BuildDisjunction creates a disjunction node (OR operation) from the given terms Handles arrays of size 0, 1, or more correctly The multiline parameter controls whether to render each term on a separate line
(multiline bool, terms ...ConditionNode)
| 432 | // Handles arrays of size 0, 1, or more correctly |
| 433 | // The multiline parameter controls whether to render each term on a separate line |
| 434 | func BuildDisjunction(multiline bool, terms ...ConditionNode) *DisjunctionNode { |
| 435 | return &DisjunctionNode{ |
| 436 | Terms: terms, |
| 437 | Multiline: multiline, |
| 438 | } |
| 439 | } |
| 440 | |
| 441 | // RenderCondition optimises a ConditionNode and renders it to a string. |
| 442 | // Use this instead of calling node.Render() directly whenever the result |
no outgoing calls