FrontPage
RecentChanges
FindPage
PageIndex
UnusedPages
UndefinedPages

Set your name in
UserPreferences

Edit this page



Referenced by
...nobody




JSPWiki v2.0.36


WhatsInAnInterfaceName

[old:WhatsInAnInterfaceName]

Whats in an interface name, and does it help or hinder TestFirstDesign and the use of MockObjects?


For example, is it a problem to prefix interfaces with "I"?

Aside from readability, does this cause any real issues for test-first design, or the substituion of a mock object as a parameter to a method?

I think it inhibits refactoring because you have to change the type name when you change its content. Personally, I prefer to put the naming wart on the implementation, not the interface, because the interfaces are the "real" system. My understanding is that the I prefix is a historical leftover from using abstract classes as interfaces in C++ --SteveF


Edit this page   More info...   Attach file...
This page last changed on 06-Mar-2002 21:27:44 GMT by unknown.