### Question:
StreamPatternMatches implements Closeable { public boolean hasNext() throws IOException { readahead(); return (matches != null && matches.hasNext()); } StreamPatternMatches(Reader input, Collection<Pattern> patterns, boolean discard); Matcher next(); boolean hasNext(); void close();  }### Answer:
@Test public void testMultiLinePatternNotMatching() throws Exception { Pattern pattern = Pattern.compile("c"); StreamPatternMatches matches = new StreamPatternMatches(Readers.reader("aab", "aab"), asList(pattern), true); assertThat(matches.hasNext()).isFalse(); }