// b.add(sysType.staticRef("out").invoke("println").arg(JExpr.lit("TD ").plus(targetDepthVar)
// .plus(JExpr.lit(" Depth: ")).plus(depthVar)
// .plus(JExpr.lit(" Name: " + name).plus(JExpr.lit(" Current: "))
// .plus(xsrVar.invoke("getName")))));
JBlock loop = b._while(depthVar.gte(targetDepthVar.minus(JExpr.lit(1)))).body();
b = loop._if(event.eq(JExpr.lit(XMLStreamConstants.START_ELEMENT)))._then();
JConditional ifDepth = b._if(depthVar.eq(targetDepthVar));