ContactUs :

Please send your Questions & Answers or Feedback to "mohan@javabook.org"

Methods of Object class............

Boolean equals(Object obj),void finalize(),int hashCode(),final void notify(),final void notifyAll(),final void wait(),
String toString().
---if u exclude primitives,everything in java is an object.Every Exception,every event,every array extends from java.lang.Object.
---if u dont override the class's equals(),you wont be able to use those objects as a key in the HashTable.
---comparing two object reference using the == operator evaluates true only when both references  refer to the same object.
---String class and Wrapper classes have overridden the equals().
---when u really need to know if two references are identical ,use ==,but when u need to know if the objects themselves(not the references)
are equal,use equals() method.
---the equals() in the class Object uses only the == operator for comparisons ,so unless u override equals(),two objects are considered equal only if the two
references refer to the same object.
---equals(),hashCode(),toString() are all public.
---HashMap,HashSet use the hashCode of an object to determine how the object should be stored in the Collection.
---HashCodes are typically used to increase the performance of large collections.
Related Posts Plugin for WordPress, Blogger...
Flag Counter