@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (getClass() != obj.getClass()) return false; Lancamento other = (Lancamento) obj; if (codigo != other.codigo) return false; if (descricao == null) { if (other.descricao != null) return false; } else if (!descricao.equals(other.descricao)) return false; if (lancamentoPai == null) { if (other.lancamentoPai != null) return false; } else if (!lancamentoPai.equals(other.lancamentoPai)) return false; if (pagamento == null) { if (other.pagamento != null) return false; } else if (!pagamento.equals(other.pagamento)) return false; if (pai != other.pai) return false; if (status != other.status) return false; if (usuario == null) { if (other.usuario != null) return false; } else if (!usuario.equals(other.usuario)) return false; if (Double.doubleToLongBits(valor) != Double.doubleToLongBits(other.valor)) return false; if (vencimento == null) { if (other.vencimento != null) return false; } else if (!vencimento.equals(other.vencimento)) return false; return true; }