Re: [PHP] OOP slow -- am I an idiot?

This is a discussion on Re: [PHP] OOP slow -- am I an idiot? within the PHP General forums, part of the PHP Programming Forums category; # cdevidaljk-phpgeneral@yahoo.com / 2006-10-15 13:59:39 -0700: > As I cannot think of a class-based ...


Go Back   Usenet Forums > PHP Programming Forums > PHP General

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #21 (permalink)  
Old 10-16-2006
Roman Neuhauser
 
Posts: n/a
Default Re: [PHP] Solution: [PHP] OOP slow -- am I an idiot?

# cdevidaljk-phpgeneral@yahoo.com / 2006-10-15 13:59:39 -0700:
> As I cannot think of a class-based way to build my report, I think
> I'll use a customer class everywhere BUT in the report. Inside the
> report I'll just use one SQL statement instead of dozens
> of instances and hundreds of queries.
>
> I'll make a note inside the class that this and that method is not the
> only place the data is accessed, to also check inside the report.
>
> Sometimes, you've just gotta compromise to get the job done. Most of
> the time, OOP is a good idea, but in this instance I don't think it's
> the best choice.


You're suffering because you're putting code that belongs in
a separate layer (data source) in the domain logic layer.
Don't blame classes for shortcomings in your design.

http://www.martinfowler.com/articles/dblogic.html

--
How many Vietnam vets does it take to screw in a light bulb?
You don't know, man. You don't KNOW.
Cause you weren't THERE. http://bash.org/?255991
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 04:05 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0