Posts

Showing posts from September, 2012

Abstract class with example

Abstract classes are classes which does not require any implementation . What ever be the methods written in the abstract clases it should be override in the derived class . The main point regarding the abstract class is that we can not create objects for the abstract classes . So the flow is like , 1)  We are writing methods in the abstract classes. Should use the keyword Abstract for the class       and should use virtual for the methods . 2)  If we need to do any operation by default whenever a method is calling, like that operations can be written        inside the virtual methods of the abstract classes .So that from some places suppose we are calling       this      method  , automatically the common operations will occur and  we can add extra functionalities       if   needed in the calling places. ...