Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re^4: How do I go from procedural to object oriented programming?

by Lady_Aleena (Priest)
on Apr 22, 2015 at 08:33 UTC ( [id://1124236]=note: print w/replies, xml ) Need Help??


in reply to Re^3: How do I go from procedural to object oriented programming?
in thread How do I go from procedural to object oriented programming?

  1. Sorry, I thought you wrote a module and script. I did not realize it was only a script. It would be very painful to have to copy and paste almost everything from line 8 to line 213 (nearly 6kb) in the current module to every script which uses the 5 hash subroutines the module currently exports. Oh guh...
  2. I had not thought about setting things up within the subroutines to check for spelling errors. I usually do that with a scratchpad script to find things which do not not belong.
  3. *blushes* I did not think to add a movie with a tbd start date.
  4. So Moo has the path from regular OO to Moo in the docs which I can reverse engineer?

Thank you very much.

No matter how hysterical I get, my problems are not time sensitive. So, relax, have a cookie, and a very nice day!
Lady Aleena

Replies are listed 'Best First'.
Re^5: How do I go from procedural to object oriented programming?
by choroba (Cardinal) on Apr 22, 2015 at 09:37 UTC
    Ad 1: I just tried to show an example. I certainly don't advise to copy and paste the same code into different places. In real life, you can have a module that populates the database, or whatever else solution you can think of.

    Ad 4: Once you understand Moo, you see the path. I doubt there's a step by step procedure described anywhere how to deMooify code.

    لսႽ† ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ
Re^5: How do I go from procedural to object oriented programming?
by Anonymous Monk on Apr 22, 2015 at 15:47 UTC
    From your reply above: "It would be very painful to have to copy and paste almost everything from line 8 to line 213 (nearly 6kb) in the current module to every script which uses the 5 hash subroutines the module currently exports. Oh guh..."

    From your homepage: "I would like this to be the last time I have to defend my use of separated values. I try to stay away from the database topic as much as possible these days whenever it comes up."

    This is where databases fit into the picture. Start kicking and screaming.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1124236]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (4)
As of 2024-03-29 10:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found