Loading src/main/java/es/redmic/brokerlib/avro/geodata/common/FeatureDTO.java +41 −0 Original line number Diff line number Diff line Loading @@ -67,4 +67,45 @@ public abstract class FeatureDTO<TProperties extends PropertiesBaseDTO, TGeometr this.geometry = geometry; } @Override public int hashCode() { final int prime = 31; int result = super.hashCode(); result = prime * result + ((geometry == null) ? 0 : geometry.hashCode()); result = prime * result + ((properties == null) ? 0 : properties.hashCode()); result = prime * result + ((type == null) ? 0 : type.hashCode()); result = prime * result + ((uuid == null) ? 0 : uuid.hashCode()); return result; } @SuppressWarnings("rawtypes") @Override public boolean equals(Object obj) { if (this == obj) return true; if (!super.equals(obj)) return false; if (getClass() != obj.getClass()) return false; FeatureDTO other = (FeatureDTO) obj; if (geometry == null) { if (other.geometry != null) return false; } else if (!geometry.equals(other.geometry)) return false; if (properties == null) { if (other.properties != null) return false; } else if (!properties.equals(other.properties)) return false; if (type != other.type) return false; if (uuid == null) { if (other.uuid != null) return false; } else if (!uuid.equals(other.uuid)) return false; return true; } } Loading
src/main/java/es/redmic/brokerlib/avro/geodata/common/FeatureDTO.java +41 −0 Original line number Diff line number Diff line Loading @@ -67,4 +67,45 @@ public abstract class FeatureDTO<TProperties extends PropertiesBaseDTO, TGeometr this.geometry = geometry; } @Override public int hashCode() { final int prime = 31; int result = super.hashCode(); result = prime * result + ((geometry == null) ? 0 : geometry.hashCode()); result = prime * result + ((properties == null) ? 0 : properties.hashCode()); result = prime * result + ((type == null) ? 0 : type.hashCode()); result = prime * result + ((uuid == null) ? 0 : uuid.hashCode()); return result; } @SuppressWarnings("rawtypes") @Override public boolean equals(Object obj) { if (this == obj) return true; if (!super.equals(obj)) return false; if (getClass() != obj.getClass()) return false; FeatureDTO other = (FeatureDTO) obj; if (geometry == null) { if (other.geometry != null) return false; } else if (!geometry.equals(other.geometry)) return false; if (properties == null) { if (other.properties != null) return false; } else if (!properties.equals(other.properties)) return false; if (type != other.type) return false; if (uuid == null) { if (other.uuid != null) return false; } else if (!uuid.equals(other.uuid)) return false; return true; } }