diff options
| author | Mark Wielaard <mark@gcc.gnu.org> | 2005-11-15 23:20:01 +0000 |
|---|---|---|
| committer | Mark Wielaard <mark@gcc.gnu.org> | 2005-11-15 23:20:01 +0000 |
| commit | 8f523f3a1047919d3563daf1ef47ba87336ebe89 (patch) | |
| tree | a5eb7cf42a51869cc8aa1fad7ad6a90cca47fdd8 /libjava/classpath/java/beans/PropertyDescriptor.java | |
| parent | 02e549bfaaec38f68307e7f34e46ea57ea1809af (diff) | |
| download | gcc-8f523f3a1047919d3563daf1ef47ba87336ebe89.tar.gz | |
Imported GNU Classpath 0.19 + gcj-import-20051115.
* sources.am: Regenerated.
* Makefile.in: Likewise.
* scripts/makemake.tcl: Use glob -nocomplain.
From-SVN: r107049
Diffstat (limited to 'libjava/classpath/java/beans/PropertyDescriptor.java')
| -rw-r--r-- | libjava/classpath/java/beans/PropertyDescriptor.java | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/libjava/classpath/java/beans/PropertyDescriptor.java b/libjava/classpath/java/beans/PropertyDescriptor.java index 416d468576f..a22d6252e28 100644 --- a/libjava/classpath/java/beans/PropertyDescriptor.java +++ b/libjava/classpath/java/beans/PropertyDescriptor.java @@ -61,7 +61,6 @@ import java.lang.reflect.Method; ** @since 1.1 ** @status updated to 1.4 **/ - public class PropertyDescriptor extends FeatureDescriptor { Class propertyType; @@ -521,6 +520,22 @@ public class PropertyDescriptor extends FeatureDescriptor return newPropertyType; } + /** + * Return a hash code for this object, conforming to the contract described + * in {@link Object#hashCode()}. + * @return the hash code + * @since 1.5 + */ + public int hashCode() + { + return ((propertyType == null ? 0 : propertyType.hashCode()) + | (propertyEditorClass == null ? 0 : propertyEditorClass.hashCode()) + | (bound ? Boolean.TRUE : Boolean.FALSE).hashCode() + | (constrained ? Boolean.TRUE : Boolean.FALSE).hashCode() + | (getMethod == null ? 0 : getMethod.hashCode()) + | (setMethod == null ? 0 : setMethod.hashCode())); + } + /** Compares this <code>PropertyDescriptor</code> against the * given object. * Two PropertyDescriptors are equals if |
