Clover coverage report -
Coverage timestamp: Fri Nov 19 2004 13:41:51 PST
file stats: LOC: 51   Methods: 6
NCLOC: 42   Classes: 1
 
 Source file Conditionals Statements Methods TOTAL
Match.java 50% 76.9% 83.3% 73.9%
coverage coverage
 1    package photospace.search;
 2   
 3    import org.apache.commons.lang.builder.*;
 4    import org.apache.lucene.index.*;
 5   
 6    public class Match
 7    implements java.io.Serializable
 8    {
 9    private String field;
 10    private String value;
 11    private int count;
 12   
 13  21 public Match(Term term, int count)
 14    {
 15  21 this.field = term.field();
 16  21 this.value = term.text();
 17  21 this.count = count;
 18    }
 19   
 20  12 public String getField()
 21    {
 22  12 return field;
 23    }
 24   
 25  8 public String getValue()
 26    {
 27  8 return value;
 28    }
 29   
 30  4 public int getCount()
 31    {
 32  4 return count;
 33    }
 34   
 35  0 public String toString()
 36    {
 37  0 return "Match[" + field + "=" + value + " (" + count + ")]";
 38    }
 39   
 40  5 public boolean equals(Object obj)
 41    {
 42  0 if (obj == null) return false;
 43  0 if (!(obj instanceof Match)) return false;
 44   
 45  5 Match that = (Match) obj;
 46  5 return new EqualsBuilder().append(this.field, that.field)
 47    .append(this.value, that.value)
 48    .append(this.count, that.count)
 49    .isEquals();
 50    }
 51    }