What is a mixin class?

Answer Posted / reeju srivastava

Mixin is a class that does not implement any method but are
in fact has only pure virtual methods. The implementor
decides the logic for these methods.

The term mixin were originally explored in the Lisp
language In C++, the term has been used to describe classes
in a particular (multiple) inheritance arrangement:

As superclasses of a single class that themselves have a
common virtual base
class .

We would like to specify an extension without pre-
determining what exactly it can extend. This is equivalent
to specifying a subclass while leaving its superclass as a
parameter to be determined later. The benefit is that a
single class can be used to express an incremental
extension, valid for a variety of classes.

Is This Answer Correct ?    3 Yes 19 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a null tree?

632


if i have same function with same number of argument but defined in different files. Now i am adding these two files in a third file and calling this function . which will get called and wht decide the precedence?

2762


How oops is better than procedural?

589


Why is polymorphism used?

586


What is the advantage of oop over procedural language?

630






What is inheritance write a program to show use of inheritance?

615


#include #include #include #include void insert(char *items, int count); int main(void) { char s[255]; printf("Enter a string:"); gets(s); insert(s, strlen(s)); printf("The sorted string is: %s.\n", s); getch(); return 0; } void insert(char *items, int count) { register int a, b; char t; for(a=1; a < count; ++a) { t = items[a]; for(b=a-1; (b >= 0) && (t < items[b]); b--) items[b+1] = items[b]; items[b+1] = t; } } design an algorithm for Insertion Sort

2170


What is the purpose of enum?

583


Why do we use polymorphism in oops?

583


What is difference between multiple inheritance and multilevel inheritance?

603


what type of question are asked in thoughtworks pair programming round ?

1766


What is methods in oop?

547


What is encapsulation with example?

581


How do you achieve polymorphism?

618


What is difference between polymorphism and inheritance?

618