@Test public void testIsEmpty() { TermQuery q1 = new TermQuery(new Term("refs", "isEmpty")); TermQuery q2 = new TermQuery(new Term("defs", "isEmpty")); TermQuery q3 = new TermQuery(new Term("hist", "isEmpty")); BooleanQuery.Builder q4 = new BooleanQuery.Builder(); q4.add(q1, Occur.MUST); q4.add(q2, Occur.MUST); BooleanQuery.Builder q5 = new BooleanQuery.Builder(); q5.add(q2, Occur.MUST); q5.add(q3, Occur.MUST); assertTrue(new HistoryContext(q1).isEmpty()); assertTrue(new HistoryContext(q2).isEmpty()); assertFalse(new HistoryContext(q3).isEmpty()); assertTrue(new HistoryContext(q4.build()).isEmpty()); assertFalse(new HistoryContext(q5.build()).isEmpty()); }
public boolean isEmpty() { return m == null; }
HistoryContext { public boolean isEmpty() { return m == null; } }
HistoryContext { public boolean isEmpty() { return m == null; } HistoryContext(Query query); }
HistoryContext { public boolean isEmpty() { return m == null; } HistoryContext(Query query); boolean isEmpty(); boolean getContext(String filename, String path, List<Hit> hits); boolean getContext(String parent, String basename, String path, Writer out, String context); boolean getContext(File src, String path, Writer out, String context); }
HistoryContext { public boolean isEmpty() { return m == null; } HistoryContext(Query query); boolean isEmpty(); boolean getContext(String filename, String path, List<Hit> hits); boolean getContext(String parent, String basename, String path, Writer out, String context); boolean getContext(File src, String path, Writer out, String context);  }