-
-
Save jshiell/1391187 to your computer and use it in GitHub Desktop.
Scala equals/hashCode/toString Live Template
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
override def toString = new ToStringBuilder(this) | |
.toString | |
override def equals(obj: Any) = obj match { | |
case other: $CLASSNAME$ => other.getClass == getClass && | |
new EqualsBuilder() | |
.isEquals | |
case _ => false | |
} | |
override def hashCode = new HashCodeBuilder(13, 19) | |
.hashCode |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment