why abstract class does not have object creation
Answer Posted / kd singh
"Abstract class has not implemented method so, we cant create the object" "The word 'Abstract' instruct the clr that not to create object of the class"
But in a simple class where we have all virtual method, able to create an object???
Also, we can define different access modified to Abstract class constructor like private, protected or public.
An abstract type is defined largely as one that can't be created. You can create subtypes of it, but not of that type itself. The CLI will not let you do this.
An abstract class has a protected constructor (by default) allowing derived types to initialize it.
| Is This Answer Correct ? | 5 Yes | 1 No |
Post New Answer View All Answers
Why are variables important in research?
Is arraylist ordered?
What is a class reference?
How to overcome the exception object reference not set to an instance of object?
What is an i/o filter?
Why are constructors used?
Make a data structure and implement an algorithm to print all the files in a directory. (The root directory can have sub-directories too.)
What is preflight request?
Can we convert list to set in java?
What is the independent variable in an experiment?
What class allows you to read objects directly from a stream in java programming?
What is use of super keyword?
If a method is declared as protected, where may the method be accessed?
What is meant by local variable and instance variable?
What are the 4 types of research methods?