/* COPYRIGHT Esri - https://js.arcgis.com/5.0.18/LICENSE.txt */
function e(e,s){e.type in s&&s[e.type]?.(e)}function*s(e){if(null==e)return;const s=[e];for(;s.length;){const e=s.pop();switch(yield e,e.type){case"when-clause":s.push(e.value),s.push(e.operand);break;case"case-expression":{const a=[];for(const s of e.clauses)a.push(s);"simple"===e.format&&a.push(e.operand),null!=e.else&&a.push(e.else);for(let e=a.length-1;e>=0;e--)s.push(a[e]);break}case"expression-list":for(let a=e.value.length-1;a>=0;a--)s.push(e.value[a]);break;case"unary-expression":s.push(e.expr);break;case"binary-expression":s.push(e.right),s.push(e.left);break;case"function":s.push(e.args);break;case"interval":s.push(e.qualifier),s.push(e.value);break;case"interval-qualifier":s.push(e.end),s.push(e.start)}}}export{s as iterateSqlNodes,e as visitSqlNode};
