Some suggestions.Yes. U r right and polymorphism is the key of OO. And it is also the base of CORBA and COM. So maybe you can read some basic topics about COM or CORBA.
-xiliu(BearDaddy);
2000-11-27{151}(#16062@0)
Thank you very much. Do you mean COM and CORBA maybe helpful for understanding the polymorphism?
-howru(How are you?);
2000-11-27(#16070@0)
u need to learn more basic knowledgeu need get to know what is virtual function and pure virtual function before u read the part of Polymorphism.
-mycli(cli);
2000-11-27{110}(#16066@0)
tks. would you please give me some details about virtual function and pure virtual function? I have no idea about them. Can you tell me one address or book to learn such functions?
thanks.tks. would you please give me some details about virtual function and pure virtual function? I have no idea about them. I'm so sorry to say it's the first time for me to hear such phenomenon. Can you tell me one address or book to learn such functions?
thanks.
-howru(How are you?);
2000-11-27{263}(#16071@0)
Some ideas.Virtual Functions are always used for interface definition, e.g. COM is based on virtual funcions list. Please read some documents about the principle of COM. It is very useful for U to understand virtual functions.
-xiliu(BearDaddy);
2000-11-27{215}(#16076@0)
For "How are you"....I think cli's suggestion is to the point. You have better slow down. I suggest you download "Thinking in Java" and look into these concepts.
-jabber(jabber);
2000-11-28{144}(#16176@0)
tks. I will go back the first chapter of Think in java again in two days.Dear Jaber,
thank you!
I downloaded Think in Java 2nd edition(from the address you told someone here). I had the book Think in Java Chinese edition(1st edition). I have read both of them several times before polymorphism. i think most of the phenomenon before polymorphism i had some sense.
I will try to finish all the excercises and examples before polymorphism in two days in the 2nd edition. Maybe it's helpful to understand the concepts.
thank you!
-howru(How are you?);
2000-11-28{469}(#16200@0)
It's said that Virtual is a keyword in C++ to use dynamic binding. If so, knowing Virtual must be very helpful for polymorphism. But, I'm so sorry to say I don't know C++ or C either. Would you please show me another way? thanks.thanks.
I read Thinking in Java again last night.
It's said that Virtual is a keyword in C++ to use dynamic binding. If so, knowing Virtual must be very helpful for polymorphism. But,
I'm so sorry to say I don't know C++ or C either. Would you please show me another way? thanks.
-howru(How are you?);
2000-11-28{294}(#16194@0)
I really appreciate your example. Just one addendum.Interfaces have many uses in Java. One is to introduce new data types. For instance, java.lang.String is an Object, but it is also a Serializable, a Comparable.
By the way, it is not necessary for an interface to contain some methods and/or static final constants. It may be empty! The example is Serializable, Cloneable. Such interfaces just introduce Data types, not any methods or final static constants.
Such a design is called the Marker Pattern.
-jabber(jabber);
2000-11-29{460}(#16379@0)
Thank you, Jabber, HH and Eric Wu. With your kind help, I got an idea about polymorphism which is just overloading and overriding based on inheritence. Maybe include some upcasting, just like HH and Mr. Wu's perfect examples. thank you very much.Thank you, Jabber, HH and Eric Wu. With your kind help, I got an idea about polymorphism. But i'm not sure whether it's right. polymorphism is just overloading and overriding. Maybe include some upcasting. I feel it's based on inheritence, just like HH and Mr. Wu's perfect examples. I think I can get more feeling with your instruction. thank you very much.
-howru(How are you?);
2000-12-2{362}(#16883@0)
Did you code using C++?find some C++ book and just read the basic concepts of C++, I think you can understand it easily. Polymorphism is not a difficult concept, and I suggest you read some good books of C++ in Chinese first,e.g. early C++ books published by Tsinhua university.
Interface and inner class are under the same situation. I think your problem is you cannot understanding english well.
-guest:guest;
2000-12-2{378}(#16875@0)
Sorry. I have no idea about C or C++. In fact, I just know well in FoxPro for DOS and know some Visual FoxPro. So Java maybe more difficult to me.
-howru(How are you?);
2000-12-3(#17003@0)