File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Query

 
vibhas karn
Greenhorn
Posts: 26
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can any buddy please help me to understand few basic concepts...I have following queries:-
1>Why a class and interface can't be declare as static?
2> What constructor really is and why we can't declare it as static abstract.
3>What does it mean that local variables are on the stack and not in the heap?
4>And why we call that the bit depth of boolen primitive type is virtual machine dependent?

Please send the reply soon......
 
Larry Frissell
Ranch Hand
Posts: 82
2
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I found many of the answers to your questions by just putting them in the "Search" above. Try that first.
 
Muhammad Saifuddin
Ranch Hand
Posts: 1324
Android Java Windows
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
please use search utility in Javaranch before post. or see the details here.
 
Minal Silimkar-Urankar
Ranch Hand
Posts: 136
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by, Vibhas Karn


Can any buddy please help me to understand few basic concepts...I have following queries:-
1>Why a class and interface can't be declare as static?

when you declares the member as static, it means that member is class related & not to the object related. There is no meaning to declare interface as static, because interfaces are made to beimplemented by the other classes, so it can not related to any specific class.


2> What constructor really is and why we can't declare it as static abstract.

Constructor is method like, but not method, which is mainly used for initialization of instance variables.
If you declare any method as abstract you must provide implementation in its imediate concrete class by overriding it.
But you can not override constructors.

Learn more on basics
[ August 12, 2008: Message edited by: minal silimkar ]
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic