aspose file tools*
The moose likes Beginning Java and the fly likes Initilization Block : Why my code goes in loop in initilization block ? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Initilization Block : Why my code goes in loop in initilization block ?" Watch "Initilization Block : Why my code goes in loop in initilization block ?" New topic
Author

Initilization Block : Why my code goes in loop in initilization block ?

ashwin bhawsar
Ranch Hand

Joined: Mar 16, 2011
Posts: 62

Why the code goes into loop at line 3 ?

Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18165
    
    8

The initialization block creates a new SampleClass object.

This causes SampleClass's initialization block to run.

The initialization block creates a new SampleClass object.

This causes SampleClass's initialization block to run.

The initialization block creates a new SampleClass object.

This causes SampleClass's initialization block to run.

The initialization block creates a new SampleClass object.

This causes SampleClass's initialization block to run.

The initialization block creates a new SampleClass object.

This causes SampleClass's initialization block to run.

The initialization block creates a new SampleClass object.

This causes SampleClass's initialization block to run.

... do I need to continue?
ashwin bhawsar
Ranch Hand

Joined: Mar 16, 2011
Posts: 62

ya, i figured it out . Thanks.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Initilization Block : Why my code goes in loop in initilization block ?
 
Similar Threads
constructor with private access modifier
Creating objects using Reflection
doubt on mutiple inheritance
Getting the current method that this executing.
Object and reference accessing for primitives, objecst and collections