Let's talk about another case where we will understand when we have multiple overloaded methods of a varargs type, Widening will beat boxing and boxing will beat var-args.
Varargs methods will always get the last priority by the JVM when there are overloaded methods. Promotion of a byte to an int (widening-conversion ) will be preferred over a var-args type method.
The reason behind this is that the language needs to be backward compatible.The older feature takes priority over the newer features. We all know varargs concept came java 1.5 version ( JDK 5).
Note: Java is backward compatible.
Stay tuned and like my Facebook page for more.
/ seleniumexpress
Music :
-----------
credits : -
(intro)
1)
Adventures by A Himitsu / a-himitsu
Creative Commons — Attribution 3.0 Unported— CC BY 3.0
http://creativecommons.org/licenses/b...
Music released by Argofox • A Himitsu - Adventures [Royalty Free Music]
Music provided by Audio Library • Adventures – A Himitsu (No Copyright Music)
2)
NCM Epic Music Ender Guney
/ ncmepicmusic
-----
intro template :
wwww.youtube.com/Alexbau01