This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes this and super keywords, array.length attribute Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "this and super keywords, array.length attribute" Watch "this and super keywords, array.length attribute" New topic
Author

this and super keywords, array.length attribute

Darshan Sharma
Greenhorn

Joined: Oct 05, 2012
Posts: 1
Hello friends,

Where the 'this' and 'super' keywords and array.length attribute are declared in the java class libraries ?

also please explain how they are initialized and how they work during runtime ?

thank you...
Matthew Brown
Bartender

Joined: Apr 06, 2010
Posts: 4344
    
    8

Hi Darshan. Welcome to the Ranch!

You won't find them in the API documentation, you need to look in the Java Language Specification if you really want the formal definition. And they're handled by the JVM - exactly how is an implementation detail that might vary between different JVMs. The way they behave is as described in the Specification.
Winston Gutkowski
Bartender

Joined: Mar 17, 2011
Posts: 7552
    
  18

Darshan Sharma wrote:Where the 'this' and 'super' keywords and array.length attribute are declared in the java class libraries ?

Except in passing, I don't think they are, they're described in the JLS.

also please explain how they are initialized and how they work during runtime ?

1. They aren't "initialized" - at least, not in the sense I think you mean.
2. For this sort of information, you should really read the Java Tutorials.

Winston

[Edit] Too slow.


Isn't it funny how there's always time and money enough to do it WRONG?
Articles by Winston can be found here
 
jQuery in Action, 2nd edition
 
subject: this and super keywords, array.length attribute
 
Similar Threads
Method Local Inner Class Question
array index in java
Simple question on testing
This and super keyword query
array size