You do NOT want one function per file.

Dog-slow.

You *MIGHT* want to group a bunch of functions logically into one
file, breaking up a monster file into "several" files.

On Fri, May 26, 2006 3:02 am, Mark Kelly wrote:
> Hi
>
> I'm writing a set of db abstraction functions for an internal app
> which will
> give us a set of simple function calls for dealing with the db, like
>
> $result = db_AddEmployee($EmployeeData);
> $EmployeeData = db_GetEmployee($EmployeeID);
>
> etc.
>
> There will be quite a few functions needed to deal with all the
> different
> ways the app touches the db, so my question is:
>
> Am I better off putting all these functions into one big include file
> (which
> could get pretty big) or using a seperate 'include' file for each
> function?
>
> I'm thinking about the tradeoff between simplifying code by only
> having a
> single include file (parsing a lot of functions that aren't used, but
> less
> disk access) and having several include files (no extra funcs but lots
> more
> disk access).
>
> I realise there probably isn't a 'correct' way to do this, I'm curious
> about
> which methods folk here use in situations like this.
>
> TIA in advance for any advice,
>
> Mark
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>


-- 
Like Music?
http://l-i-e.com/artists.htm

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to