Java View all facts Glossary Help |
principle > is-a versus has-a principle |
is-a versus has-a principle comparison table |
Subject | is a kind of | state | is a subtopic of |
---|---|---|---|
principle | kbTop | ||
is-a versus has-a principle | principle | that if you find yourself using the phrase "an X is a Y" when describing the relation between two classes, then the first class is a subclass of the second; if you find yourself using "X has a Y", then instance of the second class appear as parts of instances of the first class | Inheritance |
Next principle: look-it-up principle Up: principle Previous principle: explicit-representation principle