Watch This Video
http://docs.groovy-lang.org/latest/html/gapi/index.html?groovy/lang/Range
//Person.groovy
import groovy.transform.EqualsAndHashCode
@EqualsAndHashCode(exludes =["email"])
class Person {
String first
String last
String email
}
//app.groovy
Person p1= new Person(first:"Dan",last:"vega",email:"[email protected]")
Person p2= new Person(first:"Dan",last:"vega",email:"[email protected]")
assert p1==p2
No comments:
Post a Comment
Note: only a member of this blog may post a comment.