my dog learned polymorphism
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes Data implementation Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "Data implementation" Watch "Data implementation" New topic

Data implementation

Vinicius Florentino

Joined: Feb 26, 2008
Posts: 16
Is it possible Data implements other interface like Closeable or other created by me? Data is implementing only DB now.
Vinicius Florentino

Joined: Feb 26, 2008
Posts: 16
And if Data can implements a subinterface of DB. example:

public interface X extends DB { method

public class Data implements X...
Gilles Marceau
Ranch Hand

Joined: Feb 17, 2007
Posts: 78

in my opinion, the answers to your two questions are both yes.
You have to comply with the assignment instructions, and regarding the DB
interface and the Data class, it states that :
" must implement the DB interface".

There is no restriction on other interfaces that Data must or must not implement. And stritcly speaking, implementing a subclass of DB means
implementing DB.


SCJP 1.5<br />SCJD 1.6<br />SCBCD in progress...
I agree. Here's the link:
subject: Data implementation
It's not a secret anymore!