- Java.lang - Void
- Java.lang - Throwable
- Java.lang - ThreadLocal
- Java.lang - ThreadGroup
- Java.lang - Thread
- Java.lang - System
- Java.lang - StringBuilder
- Java.lang - StringBuffer
- Java.lang - String
- Java.lang - StrictMath
- Java.lang - StackTraceElement
- Java.lang - Short
- Java.lang - SecurityManager
- Java.lang - RuntimePermission
- Java.lang - Runtime
- Java.lang - ProcessBuilder
- Java.lang - Process
- Java.lang - Package
- Java.lang - Object
- Java.lang - Number
- Java.lang - Math
- Java.lang - Long
- Java.lang - Integer
- Java.lang - InheritableThreadLocal
- Java.lang - Float
- Java.lang - Enum
- Java.lang - Double
- Java.lang - Compiler
- Java.lang - ClassLoader
- Java.lang - Class
- Java.lang - Character.UnicodeBlock
- Java.lang - Character.Subset
- Java.lang - Character
- Java.lang - Byte
- Java.lang - Boolean
- Java.lang - Home
Java.lang Package extras
Java.lang Package Useful Resources
Selected Reading
- Who is Who
- Computer Glossary
- HR Interview Questions
- Effective Resume Writing
- Questions and Answers
- UPSC IAS Exams Notes
Java.lang.Object Class
Introduction
The java.lang.Object class is the root of the class hierarchy. Every class has Object as a superclass. All objects, including arrays, implement the methods of this class.
Class Declaration
Following is the declaration for java.lang.Object class −
pubpc class Object
Class constructors
Sr.No. | Constructor & Description |
---|---|
1 |
Object() This is the Single Constructor. |
Class methods
Sr.No. | Method & Description |
---|---|
1 | This method creates and returns a copy of this object. |
2 | This method indicates whether some other object is "equal to" this one. |
3 | This method is called by the garbage collector on an object when garbage collection determines that there are no more references to the object. |
4 | This method returns the runtime class of this Object. |
5 | This method returns a hash code value for the object. |
6 | This method wakes up a single thread that is waiting on this object s monitor. |
7 | This method wakes up all threads that are waiting on this object s monitor. |
8 | This method returns a string representation of the object. |
9 | This method causes the current thread to wait until another thread invokes the notify() method or the notifyAll() method for this object. |
10 | This method causes the current thread to wait until either another thread invokes the notify() method or the notifyAll() method for this object, or a specified amount of time has elapsed. |
11 | This method causes the current thread to wait until another thread invokes the notify() method or the notifyAll() method for this object, or some other thread interrupts the current thread, or a certain amount of real time has elapsed. |