File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Beginning Java and the fly likes static and initialization block Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Reply locked New topic

static and initialization block

vini singh

Joined: Dec 04, 2008
Posts: 18
class Bird
public Bird(){System.out.println("b2");
class Raptor extends Bird
public Raptor(){System.out.println("r2");}

class Hawk extends Raptor
public static void main(String s[])
new Hawk();

can you please tell me when exaclty is the class loaded in the memory and after which statement
James Tharakan
Ranch Hand

Joined: Aug 29, 2008
Posts: 580

Similar question

Why to worry about things in which we dont have control, Why to worry about things in which we have control ! !
Campbell Ritchie

Joined: Oct 13, 2005
Posts: 46349
Originally posted by James Tharakan:
Similar question

Agree. Shall close this thread.

Vini Singh: Please read this FAQ, and this one.
I agree. Here's the link:
subject: static and initialization block
It's not a secret anymore!