some one please send me some details on polymorphism and how it works in java. The other problem is that i want to know if java allows me to cast objects into primitive data type for example what am i supposed to do if i want to convert a string into an integer? reply soon its urgent Regards
Whole BOOKS are written on what polymorphism is in Java and you want the entire answer in a post? Why don't you check out the books at the bunkhouse http://www.javaranch.com/books.jsp We use methods to convert objects to primitives: int i = Integer.parseInt(someString);
"JavaRanch, where the deer and the Certified play" - David O'Meara
Do me another favour , please l;et me know the URL of any site where i could read more about polymorphism, its types and its uses regarding Java. tx asif
Bruce Eckel has "Thinking in Java" online at www.bruceeckel.com and the topic of polymorphism is ALL OVER JavaRanch. Do a search on the word in any on the Java in General forums, the Certification forum or the OO forum and you will get lot's of discussion on it. One of my favorite threads is here: http://www.javaranch.com/ubb/Forum24/HTML/009465.html
"JavaRanch, where the deer and the Certified play" - David O'Meara
He repaced his skull with glass. So you can see his brain. Kinda like this tiny ad:
Free, earth friendly heat - from the CodeRanch trailboss