Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

abstraction

Posted on 2006-05-08
1
Medium Priority
?
248 Views
Last Modified: 2010-03-31
Can you have an abstract class without abstract methods? explain
0
Comment
Question by:Johny24max
1 Comment
 
LVL 92

Accepted Solution

by:
objects earned 2000 total points
ID: 16635289
yes, by defining it as abstract

public abstract class MyAbstractClassWithout AbstractMethods
{
   public void xyz()
   {
       // whatever
    }
}

This would be used when you want to ensure the class must be subclassed to use
0

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Java had always been an easily readable and understandable language.  Some relatively recent changes in the language seem to be changing this pretty fast, and anyone that had not seen any Java code for the last 5 years will possibly have issues unde…
This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
The viewer will learn how to implement Singleton Design Pattern in Java.
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.
Suggested Courses
Course of the Month12 days, 2 hours left to enroll

564 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question