Win a copy of Mesos in Action this week in the Cloud/Virtualizaton forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

question about Object

 
jone wars
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i know every default no
argument constructors first
statement is super(); that is its
going to call its super class no
argument constructor. And every
class(i.e. which does not extends a
class) is child class of object. Then
my question is,what is super(); of
Object class doing???
 
Joanne Neal
Rancher
Posts: 3742
16
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
See section 8.8.9 of the Java Language Specification.
The JLS is something you should always check when you have these sort of questions about how Java functions.
 
Jesper de Jong
Java Cowboy
Saloon Keeper
Posts: 15288
39
Android IntelliJ IDE Java Scala Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome to the Ranch.

Since Object is at the root of the class hierarchy (class Object is the only one which doesn't have a superclass), there's no superclass constructor to call, so super(); would not do anything.
 
jone wars
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks..
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic