> what is meant by static class?
> how do u define it?
> where will we use it?
There are two commonly used definitions of that term. Because there are
two, it's worth being very explicit in communication about which you
mean, if it's not obvious from context.
The first meaning is a class that is merely a collection of static
things. That is, you aren't supposed to create an object of that class.
You are just supposed to call its static methods. An example is
java.lang.Math. This has been called a "static class" by many people
since at least Java 1.0.2, the initial release more than ten years ago.
I don't know if the term is used in any other languages, but I hadn't
heard it until Java.
In Java 1.1, the situation was confused by adding a second meaning.
Java 1.1 provides the option of declaring nested classes, and those can
be declared static, meaning that they aren't inner classes and therefore
don't contain a reference to an object of the outer class. So it makes
sense to call these "static". To avoid confusion, they are often called
"static nested classes" instead of just "static classes"... but it's
possible that's what your source meant.

Signature
www.designacourse.com
The Easiest Way To Train Anyone... Anywhere.
Chris Smith - Lead Software Developer/Technical Trainer
MindIQ Corporation
> what is meant by static class?
> how do u define it?
> where will we use it?
Listen - if you have 15 questions to ask then follow these simple
instructions:
Start a thread with the subject Beginner Questions/Homework Help
Then list all of your questions in a row, in the same post.
This way, if people are uninterested in helping you they can quickly mark
the thread as read.
There are pay tutor sites on the web that I imagine would LOVE to help you
answer these simple questions.
--
LTP
:)
Roedy Green - 19 Dec 2005 01:07 GMT
On Sun, 18 Dec 2005 13:45:29 -0700, "Luc The Perverse"
<sll_noSpamlicious_z_XXX_m@cc.usu.edu> wrote, quoted or indirectly
quoted someone who said :
>Listen - if you have 15 questions to ask then follow these simple
>instructions:
I disagree. I think each separate question deserves a separate thread.
You should not muddle together unrelated things in the same thread. It
makes the discussion harder to find later.

Signature
Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.
>what is meant by static class?
>how do u define it?
>where will we use it?
see http://mindprod.com/jgloss/nestedclasses.html

Signature
Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.