groovy-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Søren Berg Glasius (GR8Conf EU)" <>
Subject Re: not sure about Collection.intersect
Date Mon, 08 Feb 2016 14:31:50 GMT
And by the way,

the easy way to implement equals and haschode is this:

import groovy.transform.EqualsAndHashCode

class TestClass {
    String name

Best regards,
Søren Berg Glasius
GR8Conf Europe organizing team

GR8Conf ApS
Mobile: +45 40 44 91 88, Web:, Skype: sbglasius 
Company Address: Buchwaldsgade 50, 5000 Odense C, Denmark
Personal Address: Hedevej 1, Gl. Rye, 8680 Ry, Denmark
--- GR8Conf - Dedicated to the Groovy Ecosystem

From: Edinson E. Padrón Urdaneta <>
Reply: <>
Date: February 8, 2016 at 15:29:00
To: <>
Subject:  Re: not sure about Collection.intersect  

I have to look at the implementation of the `intersect` method to be sure but does your TestClass
class overwrite `hashcode` and `equal`? There should be a way to compare the instances of
said class.
View raw message