Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @Override
- public int hashCode() {
- final int prime = 31;
- int result = 1;
- result = prime * result + ((cronExpression == null) ? 0 : cronExpression.hashCode());
- result = prime * result + ((subject == null) ? 0 : subject.hashCode());
- result = prime * result + timeout;
- result = prime * result + ((type == null) ? 0 : type.hashCode());
- return result;
- }
- @Override
- public boolean equals(Object obj) {
- if (this == obj)
- return true;
- if (obj == null)
- return false;
- if (!(obj instanceof Reminder))
- return false;
- Reminder other = (Reminder) obj;
- if (cronExpression == null) {
- if (other.cronExpression != null)
- return false;
- } else if (!cronExpression.equals(other.cronExpression))
- return false;
- if (subject == null) {
- if (other.subject != null)
- return false;
- } else if (!subject.equals(other.subject))
- return false;
- if (timeout != other.timeout)
- return false;
- if (type == null) {
- if (other.type != null)
- return false;
- } else if (!type.equals(other.type))
- return false;
- return true;
- }
Add Comment
Please, Sign In to add comment