@Test public void testReset() throws Exception { parser.parseMoreText("\n;"); parser.parseMoreText("bob"); assertTrue(parser.hasStatements()); assertTrue(parser.containsText()); parser.reset(); assertFalse(parser.hasStatements()); assertFalse(parser.containsText()); }
@Override public void reset() { statement = new StringBuilder(); parsedStatements.clear(); awaitedRightDelimiter = Optional.empty(); }
ShellStatementParser implements StatementParser { @Override public void reset() { statement = new StringBuilder(); parsedStatements.clear(); awaitedRightDelimiter = Optional.empty(); } }
ShellStatementParser implements StatementParser { @Override public void reset() { statement = new StringBuilder(); parsedStatements.clear(); awaitedRightDelimiter = Optional.empty(); } ShellStatementParser(); }
ShellStatementParser implements StatementParser { @Override public void reset() { statement = new StringBuilder(); parsedStatements.clear(); awaitedRightDelimiter = Optional.empty(); } ShellStatementParser(); @Override void parseMoreText(@Nonnull String line); @Override boolean hasStatements(); @Nonnull @Override List<String> consumeStatements(); @Override boolean containsText(); @Override void reset(); }
ShellStatementParser implements StatementParser { @Override public void reset() { statement = new StringBuilder(); parsedStatements.clear(); awaitedRightDelimiter = Optional.empty(); } ShellStatementParser(); @Override void parseMoreText(@Nonnull String line); @Override boolean hasStatements(); @Nonnull @Override List<String> consumeStatements(); @Override boolean containsText(); @Override void reset();  }