• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Liutauras Vilda
  • Bear Bibeault
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Devaka Cooray
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Piet Souris
  • salvin francis
  • Stephan van Hulst
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Jj Roberts

Where method overloading sequence has refereed in JLS ?

 
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, I am still learning java. I have got this code in my class. I want to learn more about this what I have already learned from my class, so I searched for JLS ?

Now, what I want to know is, Where is in the JLS, I can find sequence of overloading methods when we call them or something similar to that ?
Please help...
Thank you.
Ranjith Suranga.
 
Ranji Sura
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi, I have just found this in JLS. http://docs.oracle.com/javase/specs/jls/se7/html/jls-8.html#jls-8.4.9

But , I can't get a good idea, can some one please explain...

When a method is invoked (§15.12), the number of actual arguments (and any explicit type arguments) and the compile-time types of the arguments are used, at compile time, to determine the signature of the method that will be invoked (§15.12.2). If the method that is to be invoked is an instance method, the actual method to be invoked will be determined at run-time, using dynamic method lookup (§15.12.4).



Thank you.
Ranjith Suranga
 
Rancher
Posts: 3742
16
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Ranjith Suranga wrote:But , I can't get a good idea, can some one please explain...

When a method is invoked (§15.12), the number of actual arguments (and any explicit type arguments) and the compile-time types of the arguments are used, at compile time, to determine the signature of the method that will be invoked (§15.12.2). If the method that is to be invoked is an instance method, the actual method to be invoked will be determined at run-time, using dynamic method lookup (§15.12.4).


It would help if you told us which part you didn't understand. Most of that quote seems fairly straightforward.
 
Marshal
Posts: 71094
292
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I presume by “refereed” you meant “referenced”.
I searched for that very same thing myself earlier this week: I found 4 hits, which are listed in this post.
 
Ranji Sura
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you very much.
 
Campbell Ritchie
Marshal
Posts: 71094
292
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You’re welcome
 
Wait for it ... wait .... wait .... NOW! Pafiffle! A perfect tiny ad!
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic