[interfacekit] Re: Headers splitting

On 2004-12-29 at 15:10:09 [+0100], bpmagic@xxxxxxxxxxxxxxx wrote:
> ----- Original Message -----
> From: Stefano Ceccherini <burton666@xxxxxxxxx>
> Date: Wednesday, December 29, 2004 6:36 am
> Subject: [interfacekit] Headers splitting
> 
> > I had a small e-mail exchange with Axel,
> > and we both agreed on some small changes in our public headers, but
> > we thought
> > we should ask on the list:
> > 
> > Currently, ListItem.h contains the interface declaration of
> > BListItem and also
> > the declaration of BStringItem.
> > 
> > We'd like to move BStringItem to its own header file. Obviously, in
> > order to
> > maintain source compatibility, we have to include the new header
> > file from the
> > old one.
> > 
> > There are other things like that, for example, BSeparatorItem being in
> > MenuItem.h, etc. etc.
> > 
> > The implementation will also need to be splitted (StringItem.cpp,
> > SeparatorItem.cpp, etc.)
> > 
> > What do you think ?
> Question: Why split the headers?

For clarity I'd say. One header and one source file per class (unless it is 
just a helper class of another) makes it most intuitive to find what one is 
looking for. I've already split <Mime.h> for instance (into <MimeType.h> 
for BMimeType and <Mime.h> containing various definitions and C functions).
So, I'm all for it.

CU, Ingo

Other related posts: