boolean (final Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; final ColoredFragment that = (ColoredFragment)o; return Objects.equals(myAttributes, that.myAttributes) && Objects.equals(myText, that.myText) && Objects.equals(myToolTip, that.myToolTip); }