The Object class is the parent class for all Java classes, and all classes inherit this class by default, and do not need to display the specified extends.
The class contains the following methods:
- public final native class<?> getclass ()
- public Final native void notify ()
- public final native void Notifyall () /span>
- public final native void wait (long timeout) throws Interruptedexception
- public final void Wait (long timeout, int nanos) throws interruptedexception
- public native int hashcode ()
- public boolean equals (Object obj)
- protected native Object clone () throws Clonenotsupportedexception
- protected Void Finalize () throws Throwable
Some of these methods are declared final, which means they cannot be overwritten. In practical programming, we may overwrite other methods, such as hashcode and equal, as needed.
1) GetClass
-Gets the class instance of the run-time object
2) Wait3) Notify4) Equal5) Hashcode6) Clone7) Fanalize
Java Class-object