What is an Abstract Class?
Java provides you with a special type of class, called an abstract class, which can help you, organize your classes based on common methods. An abstract class lets you put the common method names in one abstract class without having to write the actual implementation code. Following are the key points of abstract class –- Classes, which contain abstract methods, are called abstract classes.
- A program cannot instantiated an abstract class as an object.
- Abstract classes may contain a mixture of non-abstract and abstract methods. Non-abstract methods implement the method statements.
- Any subclass, which extends the class containing abstract methods, must provide the implementation for all the abstract methods; otherwise the subclass itself becomes an abstract class.
public abstract Class Book{
public abstract String readBook();
public abstract void writeBook(String text);
}
FAQ Home
Sponsored links
Build IT Knowledge with Current & Trusted Content
Helps Employees Develop & Hone New Technical Programming Skills. Sign Up & Get Full Access.
Helps Employees Develop & Hone New Technical Programming Skills. Sign Up & Get Full Access.
Check Out IT Certification Preparation Materials
Sign Up With SkillSoft & Get Access to Training Materials for Over 50 Professional Certifications.
Sign Up With SkillSoft & Get Access to Training Materials for Over 50 Professional Certifications.
SFTP components for .NET
Add complete SSH and SFTP support to your .NET framework application
Add complete SSH and SFTP support to your .NET framework application
Virtual File System SDK
Create your own file systems in Windows and .NET applications
Create your own file systems in Windows and .NET applications
PureCM Software Configuration Management
Version control and integrated issue tracking - powerful and easy to use. Get your FREE trial now!
Version control and integrated issue tracking - powerful and easy to use. Get your FREE trial now!
