(datum: object, group: SearchExpressionGroup<SearchExpressionLowercase>)
| 147 | } |
| 148 | |
| 149 | private runGroup(datum: object, group: SearchExpressionGroup<SearchExpressionLowercase>): boolean { |
| 150 | let accumulator: boolean = this.runExpression(datum, group.expressions[0]); |
| 151 | for (let i = 1; i < group.expressions.length; i++) { |
| 152 | const ex = group.expressions[i]; |
| 153 | switch (ex.clause) { |
| 154 | case '&&': |
| 155 | accumulator = accumulator && this.runExpression(datum, ex); |
| 156 | break; |
| 157 | case '||': |
| 158 | accumulator = accumulator || this.runExpression(datum, ex); |
| 159 | break; |
| 160 | } |
| 161 | } |
| 162 | return accumulator; |
| 163 | } |
| 164 | |
| 165 | run(datum: object) { |
| 166 | let accumulator = this.runGroup(datum, this.groups[0]); |
no test coverage detected