@Override public void visit(ContinueStatement statement) { try { output.writeByte(statement.getTarget() != null && statement.getTarget().getId() != null ? 10 : 11); writeLocation(statement.getLocation()); if (statement.getTarget() != null && statement.getTarget().getId() != null) { output.writeUTF(statement.getTarget().getId()); } } catch (IOException e) { throw new IOExceptionWrapper(e); } }
@Override public void visit(WhileStatement statement) { IdentifiedStatement currentBlockBackup = currentBlock; currentBlock = statement; visit(statement.getBody()); if (!hasRefs.contains(currentBlock)) { currentBlock.setId(null); } currentBlock = currentBlockBackup; }
@Override public void visit(BreakStatement statement) { try { output.writeByte(statement.getTarget() != null && statement.getTarget().getId() != null ? 8 : 9); writeLocation(statement.getLocation()); if (statement.getTarget() != null && statement.getTarget().getId() != null) { output.writeUTF(statement.getTarget().getId()); } } catch (IOException e) { throw new IOExceptionWrapper(e); } }
@Override public void visit(SwitchStatement statement) { IdentifiedStatement currentBlockBackup = currentBlock; currentBlock = statement; for (SwitchClause clause : statement.getClauses()) { visit(clause.getBody()); } visit(statement.getDefaultClause()); if (!hasRefs.contains(currentBlock)) { currentBlock.setId(null); } currentBlock = currentBlockBackup; }
block.statement.setId("block" + lastBlockId++);
@Override public void visit(WhileStatement statement) { IdentifiedStatement currentBlockBackup = currentBlock; currentBlock = statement; visit(statement.getBody()); if (!hasRefs.contains(currentBlock)) { currentBlock.setId(null); } currentBlock = currentBlockBackup; }
@Override public void visit(BreakStatement statement) { try { debugEmitter.emitStatementStart(); if (statement.getLocation() != null) { pushLocation(statement.getLocation()); } writer.append("break"); if (statement.getTarget() != null) { writer.append(' ').append(mapBlockId(statement.getTarget().getId())); } writer.append(";").softNewLine(); if (statement.getLocation() != null) { popLocation(); } } catch (IOException e) { throw new RenderingException("IO error occurred", e); } }
@Override public void visit(SwitchStatement statement) { IdentifiedStatement currentBlockBackup = currentBlock; currentBlock = statement; for (SwitchClause clause : statement.getClauses()) { visit(clause.getBody()); } visit(statement.getDefaultClause()); if (!hasRefs.contains(currentBlock)) { currentBlock.setId(null); } currentBlock = currentBlockBackup; }
@Override public void visit(ContinueStatement statement) { try { debugEmitter.emitStatementStart(); if (statement.getLocation() != null) { pushLocation(statement.getLocation()); } writer.append("continue"); if (statement.getTarget() != null) { writer.append(' ').append(mapBlockId(statement.getTarget().getId())); } writer.append(";").softNewLine(); if (statement.getLocation() != null) { popLocation(); } } catch (IOException e) { throw new RenderingException("IO error occurred", e); } }
block.statement.setId("block" + lastBlockId++);
@Override public void visit(ContinueStatement statement) { try { output.writeByte(statement.getTarget() != null && statement.getTarget().getId() != null ? 10 : 11); writeLocation(statement.getLocation()); if (statement.getTarget() != null && statement.getTarget().getId() != null) { output.writeUTF(statement.getTarget().getId()); } } catch (IOException e) { throw new IOExceptionWrapper(e); } }
@Override public void visit(BreakStatement statement) { try { output.writeByte(statement.getTarget() != null && statement.getTarget().getId() != null ? 8 : 9); writeLocation(statement.getLocation()); if (statement.getTarget() != null && statement.getTarget().getId() != null) { output.writeUTF(statement.getTarget().getId()); } } catch (IOException e) { throw new IOExceptionWrapper(e); } }
@Override public void visit(BreakStatement statement) { try { debugEmitter.emitStatementStart(); if (statement.getLocation() != null) { pushLocation(statement.getLocation()); } writer.append("break"); if (statement.getTarget() != null) { writer.append(' ').append(mapBlockId(statement.getTarget().getId())); } writer.append(";").softNewLine(); if (statement.getLocation() != null) { popLocation(); } } catch (IOException e) { throw new RenderingException("IO error occurred", e); } }
@Override public void visit(ContinueStatement statement) { try { debugEmitter.emitStatementStart(); if (statement.getLocation() != null) { pushLocation(statement.getLocation()); } writer.append("continue"); if (statement.getTarget() != null) { writer.append(' ').append(mapBlockId(statement.getTarget().getId())); } writer.append(";").softNewLine(); if (statement.getLocation() != null) { popLocation(); } } catch (IOException e) { throw new RenderingException("IO error occurred", e); } }