美文网首页
test java intermédiaire

test java intermédiaire

作者: isepien | 来源:发表于2018-12-15 06:08 被阅读0次

Language:Java; niveau:Intermédiaire


finalize()

Object
Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.

equals() vs hashcode()

the contract of the hashcode() defined in the Object class is as follows:
1.If two objects are equal according to the equals(Object) method, then calling the hashCode method on each of the two objects must produce the same integer result.
2.It is not required that if two objects are unequal according to the equals(java.lang.Object) method, then calling the hashCode method on each of the two objects must produce distinct integer results.
3.Whenever it is invoked on the same object more than once during an execution of a Java application, the hashCode method must consistently return the same integer,

Reflect Java Iterator StringBuilder vs StringBuffer

相关文章

网友评论

      本文标题:test java intermédiaire

      本文链接:https://www.haomeiwen.com/subject/rnbihqtx.html