AppletTalk.com Forum Index AppletTalk.com
Java discussions newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Interfaces are they always needed - best practise debate?

 
Post new topic   Reply to topic    AppletTalk.com Forum Index -> Java Discussions
View previous topic :: View next topic  
Author Message
Ben
Guest





PostPosted: Sat Dec 02, 2006 1:21 am    Post subject: Interfaces are they always needed - best practise debate? Reply with quote



Hi,

I'd like your views on the following to help settle an in team debate.

Common best design practise is to interface business and data access
objects.
I work in a team where this is being done for non ejb based projects
that use struts and spring, but the design and implementations don't
(currently) require any other implementations of these objects. We
follow an XP methodology.

So the question is - for these approximately 30 classes in one non ejb
project, are interfaces necessary for these singular implementations?

My personal opinion "thinking out of the box" is that I believe they are
not, since it goes against XP methodology, that it is following the
interface design paradigm blindly, it increases complexity, it increases
the required maintenance and can even reduce performance (very
debateable last point I know). IMHO Interfaces should be implemented
when the design specifically calls for it, e.g. for Spring beans that
can have multiple implementations.
I am however in the minority for thinking this in my team.

Thanks,

Ben
Back to top
William
Guest





PostPosted: Thu Jan 04, 2007 8:04 am    Post subject: Re: Interfaces are they always needed - best practise debate Reply with quote



i think to use or not depends on the scale of your project.
in my project, there are 170 classes, and we have to use
interfaces to take use of AOP of spring.


On Sat, 02 Dec 2006 03:21:48 +0800, Ben <na (AT) na (DOT) com> wrote:

Quote:
Hi,

I'd like your views on the following to help settle an in team debate.

Common best design practise is to interface business and data access
objects.
I work in a team where this is being done for non ejb based projects
that use struts and spring, but the design and implementations don't
(currently) require any other implementations of these objects. We
follow an XP methodology.

So the question is - for these approximately 30 classes in one non ejb
project, are interfaces necessary for these singular implementations?

My personal opinion "thinking out of the box" is that I believe they are
not, since it goes against XP methodology, that it is following the
interface design paradigm blindly, it increases complexity, it increases
the required maintenance and can even reduce performance (very
debateable last point I know). IMHO Interfaces should be implemented
when the design specifically calls for it, e.g. for Spring beans that
can have multiple implementations.
I am however in the minority for thinking this in my team.

Thanks,

Ben
Back to top
Display posts from previous:   
Post new topic   Reply to topic    AppletTalk.com Forum Index -> Java Discussions All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.