- Trending Categories
Data Structure
Networking
RDBMS
Operating System
Java
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
Physics
Chemistry
Biology
Mathematics
English
Economics
Psychology
Social Studies
Fashion Studies
Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
is-a relationship in Java
IS-A is a way of saying: This object is a type of that object. Let us see how the extends keyword is used to achieve inheritance.
public class Animal { } public class Mammal extends Animal { } public class Reptile extends Animal { } public class Dog extends Mammal { }
Now, if we consider the IS-A relationship, we can say −
- Mammal IS-A Animal
- Reptile IS-A Animal
- Dog IS-A Mammal
- Hence: Dog IS-A Animal as well
- Related Articles
- What is Is-a relationship in Java?
- What is Has-a relationship in Java?
- HAS-A relationship in Java
- inheritance(is-a) v/s composition (has-a) relationship in Java
- What Is Symbiotic Relationship
- What is Entity-Relationship Modeling?
- What is an Entity relationship model in DBMS?
- Binary Relationship in Database
- Ternary Relationship in Database
- What is the degree of relationship set in DBMS?
- What is the meaning of symbiotic relationship?
- Food web is constituted by(A) relationship between the organisms and the environment.(B) relationship between plants and animals.(C) various interlinked food chains in an ecosystem.(D) relationship between animals and environment.
- What is the relationship between G and g in physics?
- Entity Relationship Participation in Database
- N-ary Relationship in Database

Advertisements