"Scott Hurring" <[EMAIL PROTECTED]> wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> Depends ;-)
yea, really depnds, but as you mentioned, having parameterless
constructors are more generic, especially when it comes to derive the
classes.
>
> instead (with option #2), you could
On Wed, Jun 05, 2002 at 10:32:39PM +0100, Henry Blackman wrote:
> Do I create a new document and pass the primary key as it's a variable in
> the
>
> $document = new Document(number);
>
> and have the constructor retrieve the appropriate data from MySQL and fill
> the attribute variables.
>
> O
Depends ;-)
I'd say that the second way is probably "best", becuase
it avoids implied behaviour, which sometimes can cause
problems (lets say you want to init. a document object,
but not get anything from the DB). If you want to create
a brand new Document, obviously it won't be in the DB
alread
3 matches
Mail list logo