What is the is a and has a relation ship in oops concept in
java?
Answer Posted / raghava
OOOOOO!NOooooooooo.
is a relationship is (inheritence)
has a relationship is (composition or Assocation)
Example:
Has a relation
public class Address
{
String street;
String city;
.......
}
public class Person
{
String name;
Address address; //has a relationship
}
Is This Answer Correct ? | 82 Yes | 6 No |
Post New Answer View All Answers
How many decimal digits is 64 bit?
What does yield method of the thread class do?
Explain the use of volatile field modifier?
What are the different types of multitasking?
What is ‘has a’’ relationship in java?
What are loops in java?
What are serialization and deserialization?
When to use runnable interface vs thread class in java?
What are methods in java?
Does java list allow null?
What are the principle concepts of oops?
How can I become a good programmer?
What is a class instance variable?
How do you compare values in java?
What is difference between adapter class and listener?