public boolean equals(final Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } final AWTFontRecord that = (AWTFontRecord) o; if (bold != that.bold) { return false; } if (italics != that.italics) { return false; } if (!fontFamily.equals(that.fontFamily)) { return false; } return true; }
public int hashCode() { int result = fontFamily.hashCode(); result = 29 * result + (bold ? 1 : 0); result = 29 * result + (italics ? 1 : 0); return result; }