/** * Override of hashCode; uses descriptor name to agree with AttributeImpl * * @return hashCode for this object. */ public int hashCode() { return 37 * getDescriptor().hashCode() + (37 * (getValue() == null ? 0 : getValue().hashCode())); }
public String toString() { StringBuffer sb = new StringBuffer("SimpleFeatureImpl.Attribute: "); sb.append(getDescriptor().getName().getLocalPart()); if (!getDescriptor() .getName() .getLocalPart() .equals(getDescriptor().getType().getName().getLocalPart()) || id != null) { sb.append("<"); sb.append(getDescriptor().getType().getName().getLocalPart()); if (id != null) { sb.append(" id="); sb.append(id); } sb.append(">"); } sb.append("="); sb.append(values[index]); return sb.toString(); } }
/** * Override of hashCode; uses descriptor name to agree with AttributeImpl * * @return hashCode for this object. */ public int hashCode() { return 37 * getDescriptor().hashCode() + (37 * (getValue() == null ? 0 : getValue().hashCode())); }
/** * Override of equals. * * @param other * the object to be tested for equality. * * @return whether other is equal to this attribute Type. */ public boolean equals(Object obj) { if ( this == obj ) { return true; } if (!(obj instanceof Attribute)) { return false; } Attribute other = (Attribute) obj; if (!Utilities.equals(getDescriptor(), other.getDescriptor())){ return false; } if (!Utilities.deepEquals(getValue(), other.getValue())){ return false; } return Utilities.equals( getIdentifier(), other.getIdentifier()); }
public String toString() { StringBuffer sb = new StringBuffer("SimpleFeatureImpl.Attribute: "); sb.append(getDescriptor().getName().getLocalPart()); if (!getDescriptor().getName().getLocalPart().equals( getDescriptor().getType().getName().getLocalPart()) || id != null) { sb.append("<"); sb.append(getDescriptor().getType().getName().getLocalPart()); if (id != null) { sb.append(" id="); sb.append(id); } sb.append(">"); } sb.append("="); sb.append( values[index] ); return sb.toString(); } }
public boolean isNillable() { return getDescriptor().isNillable(); }
public Name getName() { return getDescriptor().getName(); }
public void validate() { Types.validate(getDescriptor(), values[index]); }
@Override public GeometryDescriptor getDescriptor() { return (GeometryDescriptor) super.getDescriptor(); }
/** * Override of equals. * * @param other the object to be tested for equality. * @return whether other is equal to this attribute Type. */ public boolean equals(Object obj) { if (this == obj) { return true; } if (!(obj instanceof Attribute)) { return false; } Attribute other = (Attribute) obj; if (!Utilities.equals(getDescriptor(), other.getDescriptor())) { return false; } if (!Utilities.deepEquals(getValue(), other.getValue())) { return false; } return Utilities.equals(getIdentifier(), other.getIdentifier()); }
public boolean isNillable() { return getDescriptor().isNillable(); }
public Name getName() { return getDescriptor().getName(); }
public void validate() { Types.validate(getDescriptor(), values[index]); }
@Override public GeometryDescriptor getDescriptor() { return (GeometryDescriptor) super.getDescriptor(); }