Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.php > #5256
| From | Jerry Stuckle <jstucklex@attglobal.net> |
|---|---|
| Newsgroups | comp.lang.php |
| Subject | Re: out of sheer curiosity... |
| Date | 2012-03-29 09:39 -0400 |
| Organization | A noiseless patient Spider |
| Message-ID | <jl1omm$hdm$1@dont-email.me> (permalink) |
| References | (2 earlier) <jl0boo$461$1@dont-email.me> <9tij5fFmi8U1@mid.uni-berlin.de> <jl1bei$ckh$1@dont-email.me> <jl1ehv$86a$1@news.albasani.net> <4f74567c$0$6887$e4fe514c@news2.news.xs4all.nl> |
On 3/29/2012 8:33 AM, Erwin Moller wrote: > On 3/29/2012 12:46 PM, The Natural Philosopher wrote: >> Leonardo Azpurua wrote: >>> "M. Strobel" <sorry_no_mail_here@nowhere.dee> escribi� en el mensaje >>> news:9tij5fFmi8U1@mid.uni-berlin.de... >>> >>>> Yes, this was truly an article. >>>> >>>> Next problem (or assignment) is to understand the supported paradigms, >>>> and how to use them to meet your requirements. >>>> >>>> I think of the - real or felt? - large ignorance of OO programming in >>>> PHP. >>> >>> >>> Probably felt. >>> >>> I mean, I am ignorant of much of PHP. But its support for OOP is quite >>> standard: single inheritance, interfaces, private, public and >>> protected visibility, abstract vs. concrete classes and methods. The >>> "magic methods" which I just discovered thanks to Alvaro Vicario's >>> response to my original post are sort of "idiosincratic", but >>> perfectly understandable. It lacks operator overloading (which I have >>> never actually used) and signature based overloading (which might come >>> handy, but would probably conflict with the dynamic nature of PHP >>> function calls, which I certainly prefer). >>> >>> I have been using (crippled) OO languages for the last couple of >>> decades, and my analisys and design methods are purely OO. >>> >> >> Do you know, I don't even know when my analysis and design methods are >> OO and when they are not. > > Erm... seriously TNP? > > Hint: If you use words like 'class' and 'new' you are typically in OO. > If you use functions outside a class you are typically procedural. > > I think you know. > You forget who you're talking to, Erwin. TNP is not a programmer, both by his own admission and by his posts here. It doesn't surprise me he doesn't think OO is any good. I knew a guy like that when I worked for IBM back in '90. He "read a book about it and didn't see any advantage in it". But then he wasn't a programmer, either. > >> >> Its just another way of doing things and I let my understanding of the >> problem guide me, not a set of arbitrary rules. > > As it should! > > But what 'rules' are you referring to? > > PHP's OO is pretty straightforward. > I think they did a decent job implementing OO.(php 5 that is) > > Creating smart classes is up to the programmer. > I am not aware of any extra 'rules'. > > Are you maybe referring to all kinds of design patterns scattered around > the web? > (In which case I tend to agree, because implementing other people's > solutions can take the fun out of programming. But reading them never > hurts. And when you agree to a certain approach you can even decide to > follow it yourself. It is all up to you, the programmer.) > Any rules TNP doesn't bother to understand are "arbitrary" in his mind. He doesn't even like having to follow PHP syntax rules - as he has also said in the past. But I disagree that PHP 5's implementation of OO is decent. I think it's half-assed at best. Truly written by people who have no understanding of OO. But then that can be said of a lot of PHP. >> >> I dont use OOP languages, because having read up on them extensively >> when they first appeared I simply thought 'oh, ok, I see where they are >> coming from' and incorporated a few ideas about how code and data should >> be organised in pseudo object form, and moved on. The benefits are in >> the way of looking at things, not enforcing a set of strictures on >> programming. Especially when many coding problems do not lend themselves >> to those strictures. > > True, but also a truism. > "If a certain problem is unfit for OO approach, it is unfit for OO > approach." > > But even then, OO often won't hurt too much either. > You can simply use your procedural logic in OO too. > I worked like that in Java when I started learning the language, until I > discovered how idiotic I was. All part of the learning curve. :-) > I agree - I've seen some things which work better using a procedural approach. But I've also found the more complicated something gets, the more appropriate an OO approach becomes. It's like designing a soap box derby racer vs. an SUV. I'd build a kids racer out of raw materials. It's small, simple and relatively easy. However, do you think car manufacturers do it this way? Or do they take an engine from one model, modify the body style from another, etc.? And if they don't have the right engine, do they design that as part of the car? Or do they specify the dimensions, mounting, etc. and separately design the engine to that specification? No, they don't have to do it that way - they could design each piece from the bottom up. And then if they change the seats from bench to bucket, they might find an interdependency and have to also change spark plugs. > >> >> (and almost all of the problems to which PHP is the natural language of >> choice do not benefit from OOP. If a web site is the application each >> php 'page' is an object in its own right..anyway. > > True for a simple plain webpage, but when you have something more > complex OO can certainly help. > Most (all?) modern MVC software are at least partly OO, simply because > it makes things easier to organize. > No, a page is not an object. A page is closer to a transactional application. For instance, the page cannot be reused in another page without modifications. Objects can. > With OO you don't have to drag all the information around to each > function that (might) need it. And scope is better organized: more > intuitive. > > OO makes things easier to organize, that's all, but it DOESN'T define > how to solve your problem at hand. > > Very true. > >> Neither are >> microprocessors in the end object oriented. Object orientation stresses >> the structure of data, whereas procedural coding stresses the way in >> which processing is carried out.) > > Both true, but I don't think that the exact implementation on some > microprocessor is relevant for >99% of all programmers. > That's because if it isn't good for microprocessors, it must not be good for anything, according to TNP. > Most programmers have no clue how to code directly for a cpu. > The last microprocessor I coded directly was the 6502. > I have NO IDEA how to code for my current quadcode, and I don't care > either. > > We have compilers and interpreters and bytecode and what's more to solve > that. > Programmers focus on the task at hand, often in a high level language. > And OO is a very fine addition. > Give it another try one day. :-) > I can code Intel processors - I started back in '82 when the typical PC had 64K or 128K of RAM (and slow). We needed to do some stuff in 808x assembler. I still do a little as a hobby (mainly to keep up with it), but I don't go down to the OS level. > > Regards, > Erwin Moller > > > -- ================== Remove the "x" from my email address Jerry Stuckle JDS Computer Training Corp. jstucklex@attglobal.net ==================
Back to comp.lang.php | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
out of sheer curiosity... "Leonardo Azpurua" <leonardo@exmvps.org> - 2012-03-27 12:31 -0430
Re: out of sheer curiosity... "Álvaro G. Vicario" <alvaro.NOSPAMTHANX@demogracia.com.invalid> - 2012-03-27 19:06 +0200
Re: out of sheer curiosity... "Leonardo Azpurua" <leonardo@exmvps.org> - 2012-03-27 13:04 -0430
Re: out of sheer curiosity... Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2012-03-28 21:12 +0200
Re: out of sheer curiosity... "Leonardo Azpurua" <leonardo@exmvps.org> - 2012-03-28 20:23 -0430
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-03-29 10:00 +0200
Re: out of sheer curiosity... "Leonardo Azpurua" <leonardo@exmvps.org> - 2012-03-29 05:23 -0430
Re: out of sheer curiosity... The Natural Philosopher <tnp@invalid.invalid> - 2012-03-29 11:46 +0100
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-03-29 14:02 +0200
Re: out of sheer curiosity... Erwin Moller <erwinmollerusenet@xs4all.nl> - 2012-03-29 14:33 +0200
Re: out of sheer curiosity... The Natural Philosopher <tnp@invalid.invalid> - 2012-03-29 14:37 +0100
Re: out of sheer curiosity... Erwin Moller <erwinmollerusenet@xs4all.nl> - 2012-03-29 15:59 +0200
Re: out of sheer curiosity... The Natural Philosopher <tnp@invalid.invalid> - 2012-03-29 17:58 +0100
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-03-29 09:39 -0400
Re: out of sheer curiosity... Erwin Moller <erwinmollerusenet@xs4all.nl> - 2012-03-29 16:21 +0200
Re: out of sheer curiosity... The Natural Philosopher <tnp@invalid.invalid> - 2012-03-29 18:09 +0100
Re: out of sheer curiosity... Tim Streater <timstreater@greenbee.net> - 2012-03-29 22:07 +0100
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-03-29 23:43 +0200
Re: out of sheer curiosity... The Natural Philosopher <tnp@invalid.invalid> - 2012-03-30 04:52 +0100
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-03-29 16:11 -0400
Re: out of sheer curiosity... Tim Streater <timstreater@greenbee.net> - 2012-03-29 22:01 +0100
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-03-29 19:29 -0400
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-04-08 22:50 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-08 17:15 -0400
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-04-09 00:39 +0200
Re: out of sheer curiosity... The Natural Philosopher <tnp@invalid.invalid> - 2012-04-09 00:59 +0100
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-08 20:28 -0400
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-08 20:24 -0400
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-04-09 11:29 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-09 08:27 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-09 15:20 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-09 12:03 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-09 20:04 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-09 14:37 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-09 22:50 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-09 20:17 -0400
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-04-10 10:05 +0200
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 13:28 +0200
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-04-10 18:54 +0200
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 20:10 +0200
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-04-10 20:23 +0200
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 23:17 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 17:11 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 23:30 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 19:43 -0400
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 17:08 -0400
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-04-11 10:40 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 07:58 -0400
Re: out of sheer curiosity... Tim Streater <timstreater@greenbee.net> - 2012-04-10 16:04 +0100
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 12:10 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 18:18 +0200
Re: out of sheer curiosity... The Natural Philosopher <tnp@invalid.invalid> - 2012-04-10 18:20 +0100
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-04-10 19:31 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 17:20 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 23:57 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 19:50 -0400
Re: out of sheer curiosity... Tim Streater <timstreater@greenbee.net> - 2012-04-10 17:41 +0100
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 17:25 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 12:16 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 13:44 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 08:04 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 17:37 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 12:19 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 18:44 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 17:23 -0400
Re: out of sheer curiosity... Scott Johnson <noonehome@chalupasworld.com> - 2012-04-09 11:50 -0700
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-09 23:03 +0200
Re: out of sheer curiosity... Scott Johnson <noonehome@chalupasworld.com> - 2012-04-09 15:27 -0700
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-09 20:25 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 12:48 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 08:06 -0400
Re: out of sheer curiosity... "Leonardo Azpurua" <leonardo@exmvps.org> - 2012-04-10 07:52 -0430
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 12:20 -0400
Re: out of sheer curiosity... "Leonardo Azpurua" <leonardo@exmvps.org> - 2012-04-10 12:03 -0430
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 17:28 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-11 00:13 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 19:53 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-11 22:17 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-11 16:30 -0400
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-09 20:22 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 12:43 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 08:11 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 18:15 +0200
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-04-10 19:09 +0200
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 20:17 +0200
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-04-10 20:25 +0200
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-10 23:21 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 17:34 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-11 01:00 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-10 19:54 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-11 22:10 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-11 16:31 -0400
Re: out of sheer curiosity... Thomas Mlynarczyk <thomas@mlynarczyk-webdesign.de> - 2012-04-11 22:40 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-12 00:02 -0400
Re: out of sheer curiosity... "M. Strobel" <sorry_no_mail_here@nowhere.dee> - 2012-04-12 12:00 +0200
Re: out of sheer curiosity... Jerry Stuckle <jstucklex@attglobal.net> - 2012-04-12 07:45 -0400
csiph-web