in reply to Re: OO or just OOps ?
in thread OO or just OOps ?
You write about a single class Orderconfirmer which all methods belong to.
Using a singleton gains little compared to
IMVHO (v stands for very)my %obj; fetchdata(\%obj, type => all); fetchdata(\%obj, name => 'foo'); createinvoice(\%obj, type => 'msword', name => 'foo);
It is in fact how my abovementioned non-OO version was designed.
What I wanted was to put different things in different classes, having their own methods and accessors.
I guess 5-6 classes would seem resonably for this application, some classes would have just one instance and others like ORDER and ITEM would have plenty of instances, created and populated during data fetch. These instances would have to be accessed during the invoice building so there needs to be a way to access instances of other classes there.
And that was my real question from the beginning, even though I failed to communicate that.
The real problem is that I don't have any OO background, apart from Damians book, Perl toot and Perl boot, (thanks merlyn)
Anyway thanks for your input, things seem to demuddle as I try to explain myself.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: OO or just OOps ?
by Anonymous Monk on Sep 24, 2002 at 03:00 UTC |