Back to project page AndroidWeatherBuoyDemo.
The source code is released under:
Apache License
If you think the Android project AndroidWeatherBuoyDemo listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.kevinrschultz.weatherbuoy.model; /* w ww . j a v a 2 s . c om*/ import com.google.common.base.Objects; /** * @author Kevin Schultz (kschultz@gilt.com) */ public class BuoyDescription { private static final String TAG = BuoyDescription.class.getSimpleName(); private int id; private String name; public BuoyDescription(int id, String name) { this.id = id; this.name = name; } public int getId() { return id; } public String getName() { return name; } /** * Object methods */ @Override public boolean equals(Object o) { if (this == o) return true; boolean equal = false; if (o instanceof BuoyDescription) { BuoyDescription other = (BuoyDescription) o; equal = Objects.equal(this.id, other.id) && Objects.equal(this.name, other.name); } return equal; } @Override public String toString() { return Objects.toStringHelper(TAG) .add("id", id) .add("name", name) .toString(); } }