Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #26496

Re: java inheritance

Date 2013-11-11 09:40 -0500
From Arne Vajhøj <arne@vajhoej.dk>
Newsgroups comp.lang.java.programmer
Subject Re: java inheritance
References <88bf3eb6-4f5a-4745-9bea-fcc4bdaba816@googlegroups.com>
Message-ID <5280ec6d$0$301$14726298@news.sunsite.dk> (permalink)
Organization SunSITE.dk - Supporting Open source

Show all headers | View raw


On 11/11/2013 8:30 AM, asdf9797 wrote:
> I did a java test recently and one of the questions was on the subject of
> inheritance/ OO design
>
> The idea was there was a "Storable" abstract class which contained a store() method.
>
> There was a IStorable interface
>
> And then there was
>
> class Book extends Storable implements IStorable {
>     public void save(Book) {
>     }
>
> }
> The question was how to improve the implementation.
>
> What is the current thinking on extending abstract classes ?
>
> Is that the issue?

The construct of:
- an interface
- an abstract base class with common logic that that are good for most 
implementations
- some concrete classes that extends the abstract base class
is widely used.

The question probably relates to something very specific in the text.

Arne

Back to comp.lang.java.programmer | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

java inheritance asdf9797 <paul.caffrey@gmail.com> - 2013-11-11 05:30 -0800
  Re: java inheritance Eric Sosman <esosman@comcast-dot-net.invalid> - 2013-11-11 09:12 -0500
  Re: java inheritance Arne Vajhøj <arne@vajhoej.dk> - 2013-11-11 09:40 -0500
  Re: java inheritance markspace <markspace@nospam.nospam> - 2013-11-11 09:45 -0800
    Re: java inheritance Arved Sandstrom <asandstrom2@eastlink.ca> - 2013-11-18 09:24 -0400
  Re: java inheritance Robert Klemme <shortcutter@googlemail.com> - 2013-11-11 19:19 +0100

csiph-web