All the methods of Object are inherited by every class. : Object « Utility Classes « SCJP

Home
SCJP
1.Java Source And Data Type
2.Operators
3.Modifiers
4.Type Casting
5.Statements
6.Object Oriented
7.Thread
8.Utility Classes
9.File
SCJP » Utility Classes » Object 
8.1.2.All the methods of Object are inherited by every class.
public class MainClass {
  public static void main(String[] argv) {
    MyClass my = new MyClass();
    System.out.println(my.toString());
  }
}

class MyClass {
}
8.1.Object
8.1.1.The Object class is the ultimate ancestor of all Java classes.
8.1.2.All the methods of Object are inherited by every class.
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.