/** * Returns the hash code value for this validation message. * This implementation computes and returns the hash based * on the hash code values of this messages' severity, key, * and text. * * @return the hash code value for this validation message. * * @see Object#hashCode() */ @Override public int hashCode() { String formattedText = formattedText(); int result = 17; result = 37 * result + severity().hashCode(); result = 37 * result + (key() == null ? 0 : key().hashCode()); result = 37 * result + (formattedText == null ? 0 : formattedText.hashCode()); return result; }
/** * Returns the hash code value for this validation message. * This implementation computes and returns the hash based * on the hash code values of this messages' severity, key, * and text. * * @return the hash code value for this validation message. * * @see Object#hashCode() */ @Override public int hashCode() { String formattedText = formattedText(); int result = 17; result = 37 * result + severity().hashCode(); result = 37 * result + (key() == null ? 0 : key().hashCode()); result = 37 * result + (formattedText == null ? 0 : formattedText.hashCode()); return result; }
/** * Returns the hash code value for this validation message. * This implementation computes and returns the hash based * on the hash code values of this messages' severity, text, * target, role, and property.<p> * * If this class could be extended, we should check if the formatted text * is {@code null}. * * @return the hash code value for this validation message. * * @see Object#hashCode() */ @Override public int hashCode() { int result = 17; result = 37 * result + severity().hashCode(); result = 37 * result + (text() == null ? 0 : text().hashCode()); result = 37 * result + (target() == null ? 0 : target().hashCode()); result = 37 * result + (role() == null ? 0 : role().hashCode()); result = 37 * result + (property() == null ? 0 : property().hashCode()); return result; }
/** * Returns the hash code value for this validation message. * This implementation computes and returns the hash based * on the hash code values of this messages' severity, text, * target, role, and property.<p> * * If this class could be extended, we should check if the formatted text * is {@code null}. * * @return the hash code value for this validation message. * * @see Object#hashCode() */ @Override public int hashCode() { int result = 17; result = 37 * result + severity().hashCode(); result = 37 * result + (text() == null ? 0 : text().hashCode()); result = 37 * result + (target() == null ? 0 : target().hashCode()); result = 37 * result + (role() == null ? 0 : role().hashCode()); result = 37 * result + (property() == null ? 0 : property().hashCode()); return result; }