Finds the index of an expression in a list, comparing using SqlNode#equalsDeep(SqlNode, Litmus).
(List<? extends SqlNode> list, SqlNode e,
Litmus litmus)
| 168 | /** Finds the index of an expression in a list, comparing using |
| 169 | * {@link SqlNode#equalsDeep(SqlNode, Litmus)}. */ |
| 170 | public static int indexOfDeep(List<? extends SqlNode> list, SqlNode e, |
| 171 | Litmus litmus) { |
| 172 | for (int i = 0; i < list.size(); i++) { |
| 173 | if (e.equalsDeep(list.get(i), litmus)) { |
| 174 | return i; |
| 175 | } |
| 176 | } |
| 177 | return -1; |
| 178 | } |
| 179 | |
| 180 | /** |
| 181 | * Returns whether a node represents the NULL value. |
no test coverage detected