jclouds-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Adrian Cole <notificati...@github.com>
Subject Re: [jclouds-labs-aws] JCLOUDS-750: Refactor glacier domain classes using @AutoValue (#64)
Date Thu, 30 Oct 2014 17:45:14 GMT
>  
> -   @Override
> -   public boolean equals(Object obj) {
> -      if (obj == null)
> -         return false;
> -      if (getClass() != obj.getClass())
> -         return false;
> -      ArchiveMetadata other = (ArchiveMetadata) obj;
> +   public abstract HashCode getTreeHash();

Please keep natural types in value objects. This helps in portability.  Ex. `public abstract
String sha256TreeHash()`

Move anything that actually requires this being a HashCode object to the call site.

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-labs-aws/pull/64/files#r19622455
Mime
View raw message