SitePoint Sponsor

User Tag List

Page 3 of 3 FirstFirst 123
Results 51 to 60 of 60

Thread: Oop's

  1. #51
    Coding and Breathing CoderMaya's Avatar
    Join Date
    Feb 2008
    Location
    Atlit, Israel
    Posts
    470
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Mhm. And why's that?
    Learn about the new Retro Framework
    Code PHP the way it was meant to be coded!

  2. #52
    SitePoint Wizard silver trophybronze trophy Stormrider's Avatar
    Join Date
    Sep 2006
    Location
    Nottingham, UK
    Posts
    3,133
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Because a lot of people, yourself, logic_earth and arkinstall included, use it as a class name. If you tried to integrate with a third party form or whatever, and they did the same, you are a bit screwed!

  3. #53
    . shoooo... silver trophy logic_earth's Avatar
    Join Date
    Oct 2005
    Location
    CA
    Posts
    9,013
    Mentioned
    8 Post(s)
    Tagged
    0 Thread(s)
    ^^^ Actually I use...So for me clashes shouldn't happen unless they use the same namespace setup, etc.
    PHP Code:
    # String Object:
    $s = new PHP::Common::String::Object'string' );
    # String Function
    $s PHP::Common::String::replace$s'needle''blah' ); 
    PHP 5.3 Namespaces. <3
    Logic without the fatal effects.
    All code snippets are licensed under WTFPL.


  4. #54
    SitePoint Wizard silver trophybronze trophy Stormrider's Avatar
    Join Date
    Sep 2006
    Location
    Nottingham, UK
    Posts
    3,133
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Yes, but you get my point :P Before namespaces, you could have had problems.

  5. #55
    SitePoint Wizard silver trophybronze trophy Cups's Avatar
    Join Date
    Oct 2006
    Location
    France, deep rural.
    Posts
    6,869
    Mentioned
    17 Post(s)
    Tagged
    1 Thread(s)
    Quote Originally Posted by Lamiunto
    Going against the grain and basically rebelling against standard php function names is going to do you more harm than good in my opinion.
    Quote Originally Posted by Rasmus Lerdorf
    "get over it" . PHPConference London Jan 2007
    I agree with those two statements

    But ...

    Quote Originally Posted by Coder Maya
    And arkinstall, what I hate more than the naming convention is that they change parameter placement with each function. Best example: array-value functions. One time the first parameter is array, one time it's the value or key... And that's just irritating.
    Got to nod at that one though ...

    However two ideas struck me reading this thread.

    I could see the value of the static class if my mother tongue was not english.

    texte::aMajuscule()
    texte::aMinuscule()

    correct use of uppercase in french

    That'd be nice, as in nice and kind.

    and...

    To make all this a bit faster, wouldn't you go one step further and write and an extension to the language in C?
    Would that actually work?
    ( I have wandered out of my comfort zone, so I don't know if that's a stupid remark)

    But if there was a pecl extension for french speaking developer, it'd be very popular. However isn't that what PHP6 is supposed to in some way help accomplish.
    Last edited by Cups; Sep 5, 2008 at 12:03. Reason: typos in french, additions in italics

  6. #56
    Coding and Breathing CoderMaya's Avatar
    Join Date
    Feb 2008
    Location
    Atlit, Israel
    Posts
    470
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Stormrider View Post
    Because a lot of people, yourself, logic_earth and arkinstall included, use it as a class name. If you tried to integrate with a third party form or whatever, and they did the same, you are a bit screwed!
    That can be said on any user defined class or function. Thus => Irrelevant argument.
    Learn about the new Retro Framework
    Code PHP the way it was meant to be coded!

  7. #57
    SitePoint Wizard silver trophybronze trophy Stormrider's Avatar
    Join Date
    Sep 2006
    Location
    Nottingham, UK
    Posts
    3,133
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Yes, it could. But you were arguing that because you had them all in a static class, you wouldn't get clashes, which is just rubbish.

  8. #58
    Coding and Breathing CoderMaya's Avatar
    Join Date
    Feb 2008
    Location
    Atlit, Israel
    Posts
    470
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    It seems like you're reading text like a machine, not a thinking human. Try to understand the point.

    I was saying that while I could start using a pattern of function names, such as string_split, string_something I could end up (not necessarily with the 'string' functions but other names too) with one function that already exists in PHP. So that would ruin my pattern, I want to use my function name and not have to think about other ways to describe them now just because the function name already exist.

    I was talking about doing it directly on PHP. Either way, in a team effort, we would create one class that would fit us all. I don't know how you work, but there's this thing called cooperation, not blindly "hey this is the module I made", "cool, here's mine!". Maybe you made such a ridiculous point because that's how you work in a team, but that's not the smart not acceptable way of doing it.
    Learn about the new Retro Framework
    Code PHP the way it was meant to be coded!

  9. #59
    SitePoint Wizard silver trophybronze trophy Stormrider's Avatar
    Join Date
    Sep 2006
    Location
    Nottingham, UK
    Posts
    3,133
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Yes, you might end up with a function that exists in php... so you wouldn't even have to code your own!

    Or you could use the php functions in the first place. Yes, they have odd naming conventions, but it really doesn't take that much effort to get used to it.

    And please don't assume things about the way I work, because you don't have a clue.

  10. #60
    Coding and Breathing CoderMaya's Avatar
    Join Date
    Feb 2008
    Location
    Atlit, Israel
    Posts
    470
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm talking about function names, not content.
    And yes, for the who knows what time, I could use the built-in names, but my code would look ugly. Not to mention you don't always even have a syntax highlighter, in which case proper names matter even more.

    And my assumptions were only based on your arguments.

    On a final note - let's pretend to respect each other's views. Future/current readers each have read both our arguments by now and decided about their preference.There's no need to continue. So thank you for participating in the debate. It was a pleasure.
    Learn about the new Retro Framework
    Code PHP the way it was meant to be coded!


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •