3 What is the difference between a superclass and a subclass

3. What is the difference between a “superclass” and a “subclass”? How are superclass-subclass relationships represented in the UML?in 100 words

Solution

Answer :-

difference between superclass and subclass :

1) A super class is a class that is inherited whereas sub class is a class that does the inheriting.

2) Super class refers to a high level class, which passes some kind of attribute and procedures. This is usually followed down to the hierarchy to subclasses. Most of the time abstract super classes are referred to as master structures and almost most of the time no objects are created for it.

3) a subclass is that inherits different kinds of specifications and also behaviors. This could also include methods, procedures and variables from any other class.

4) super class is a simple class that generally sub class is a class that inheritance from super class; and can use method or data type in super class(if method or datatype use as public) .

5) EMPLOYEE entity SECRETARY , MANAGER , ENGINEER . The set of entities in each of latter grouping is a subset of the entities that belongto the EMPLOYEE entity set . We call each of these subgrouping a subclass of the EMPLOYEE entity type , and the EMPLOYEE entity type is the superclass gor each of these subclasses.

3. What is the difference between a “superclass” and a “subclass”? How are superclass-subclass relationships represented in the UML?in 100 wordsSolutionAnswer :

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site