When should i use abstract classes and interfaces, JAVA Programming

Assignment Help:

When should I use abstract classes and when should I use interfaces?

 Use Interface, when:

  • Design changing often or when various implementations only share method signatures.
  • When we need some classes to use some methods which we don't want to be included in class.

Use Abstract Class, when:

  • Several implementations are of the same kind and use common behavior.
  • Enabling with generalized form of abstraction and leave implementation task with inheriting subclass.
  • creating planned inheritance hierarchies

 


Related Discussions:- When should i use abstract classes and interfaces

What is the basic difference between threads and processes? , A process is ...

A process is an execution of a code but a thread is a single execution sequence within the process. A process may contain multiple threads. A thread is sometimes named a lightweigh

Relate java with JVM, Relate java with JVM Java performance gets better...

Relate java with JVM Java performance gets better each year as JVM gets smarter. This works, since making JVM smarter doesn't require any great change to the java language, sou

Starting in new app, iam trying to build an application that store informat...

iam trying to build an application that store information like name mobile age in a file its like a registration form everytime i enter a new person data i want the applicaion mak

Create a fifa coins website, Project Description: I want to create simil...

Project Description: I want to create similar site: fifacointrader I want similar site like fifacointrader.com Skills required are HTML, Java, PHP, Website Design, Wordpre

K-means clustering, i) Set the number of data points to 20 and the number o...

i) Set the number of data points to 20 and the number of clusters to 2. Check box Show History. Click on Initialize. Click on Start. Click on Step . Observe which points ch

How marketing strategies are changed along with the progress, How marketing...

How marketing strategies are changed along with the progress in computing? How latest marketing strategies are implemented? Marketing Strategy Changes along with the latest req

Write html and javascript code for the needs, Write HTML and JavaScript cod...

Write HTML and JavaScript code for the needs shown in the diagram below? When ConvertoUpperCase button is pressed then the entered text is converted to upper case and result is

Arraya, what is arrays and how do they operate

what is arrays and how do they operate

Explain the 4 phases of RUP?, 1. Inception : In the mean while the inc...

1. Inception : In the mean while the inception phase, you work out the business part for the project. You also will be creating a rough cost estimate and return on investment.

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd