
October 9th, 2003, 11:18 PM
|
|
Contributing User
|
|
Join Date: Aug 2003
Location: Brisbane, Australia
Posts: 50
Time spent in forums: < 1 sec
Reputation Power: 10
|
|
|
nonstatic variable is called "class variable" in my old java text book
and I do recall that outter class and inner class relationship is like : outter class inherits inner class
which means you have your constructor defined like this:
public OutterClassObject(): InnerClassObject
{
//construction code
}
to access the inner class class variable, you must have your inner class class variable defined as protect or public. You cannot access private inner class class variable.
Those accessibility rule are inherited from C++
by the way, if you are after something like manual63 says, then here is a further note of the rules:
you cannot access class variable by static method (or global calls) simply because your class was never "constructed" when you do a static call or global call.
|