SlideShare ist ein Scribd-Unternehmen logo
1 von 54
Downloaden Sie, um offline zu lesen
id:lapis25
            lapis25@gmail.com
Kansai.pm Meeting #8/20070310
Larry Wall




070310   Kansai.pm Meeting #8/01-Perl-oo   2
070310   Kansai.pm Meeting #8/01-Perl-oo   3
•

•

•


070310   Kansai.pm Meeting #8/01-Perl-oo   5
070310   Kansai.pm Meeting #8/01-Perl-oo   6
070310   Kansai.pm Meeting #8/01-Perl-oo   7
070310   Kansai.pm Meeting #8/01-Perl-oo   8
070310   Kansai.pm Meeting #8/01-Perl-oo   9
070310   Kansai.pm Meeting #8/01-Perl-oo   10
package Class;




070310      Kansai.pm Meeting #8/01-Perl-oo   11
070310   Kansai.pm Meeting #8/01-Perl-oo   12
•

•




070310   Kansai.pm Meeting #8/01-Perl-oo   13
package Class;

         sub method {
             #
         }




070310         Kansai.pm Meeting #8/01-Perl-oo   14
$obj_ref->method('args');




   Class::method($obj_ref, 'args');




070310      Kansai.pm Meeting #8/01-Perl-oo   15
package Class;
         sub method {
             my ($self, @args) = @_;
             #
         }




070310          Kansai.pm Meeting #8/01-Perl-oo   16
070310   Kansai.pm Meeting #8/01-Perl-oo   17
070310   Kansai.pm Meeting #8/01-Perl-oo   18
070310   Kansai.pm Meeting #8/01-Perl-oo   19
bless $hash_ref, 'Class';


•
•



070310         Kansai.pm Meeting #8/01-Perl-oo   20
#A bless
print ref($hash_ref);
                                                 $hash_ref
#HASH

bless $hash_ref, 'Class';
#B bless
print ref($hash_ref);
                                                    Class
#Class
                               _id               '01'
                               _type             'script'
                               _name             'Perl'


  070310       Kansai.pm Meeting #8/01-Perl-oo            21
070310   Kansai.pm Meeting #8/01-Perl-oo   22
070310   Kansai.pm Meeting #8/01-Perl-oo   23
070310   Kansai.pm Meeting #8/01-Perl-oo   24
package Class;
  sub new {
    my ($class, @args) = @_;
    return bless { @args }, $class;
  }




070310      Kansai.pm Meeting #8/01-Perl-oo   25
$obj_ref = Class->new( $id, $type );




$obj_ref = Class::new('Class',$id, $type);




070310        Kansai.pm Meeting #8/01-Perl-oo   26
• DESTROY
•
•




070310      Kansai.pm Meeting #8/01-Perl-oo   27
070310   Kansai.pm Meeting #8/01-Perl-oo   28
•
•

•
•




070310   Kansai.pm Meeting #8/01-Perl-oo   29
070310   Kansai.pm Meeting #8/01-Perl-oo   30
package PerlHacker;
   use base qw( Programmer Obfuscator );



   package Programmer;
   use base qw( Coder Documenter );




070310        Kansai.pm Meeting #8/01-Perl-oo   31
Coder           Documenter


     use base qw( Coder Documenter );

                  Programmer              Obfuscator


         use base qw( Programmer Obfuscator );

                            PerlHacker



070310            Kansai.pm Meeting #8/01-Perl-oo      32
Coder           Documenter




           Programmer               Obfuscator




                      PerlHacker



070310      Kansai.pm Meeting #8/01-Perl-oo      33
070310   Kansai.pm Meeting #8/01-Perl-oo   34
070310   Kansai.pm Meeting #8/01-Perl-oo   35
070310   Kansai.pm Meeting #8/01-Perl-oo   36
070310   Kansai.pm Meeting #8/01-Perl-oo   37
070310   Kansai.pm Meeting #8/01-Perl-oo   38
•
•
•
•
•
•


070310   Kansai.pm Meeting #8/01-Perl-oo   39
070310   Kansai.pm Meeting #8/01-Perl-oo   40
070310   Kansai.pm Meeting #8/01-Perl-oo   41
070310   Kansai.pm Meeting #8/01-Perl-oo   42
070310   Kansai.pm Meeting #8/01-Perl-oo   43
• Class::Accessor(::fast)
   –
• Class::Data::Inheritable
   –




070310   Kansai.pm Meeting #8/01-Perl-oo   44
• NEXT
   –        Catalyst
   –

• Class::C3
   – DBIC
   –
                  C3
               NEXT

070310         Kansai.pm Meeting #8/01-Perl-oo   45
Class::Std




070310   Kansai.pm Meeting #8/01-Perl-oo   46
070310   Kansai.pm Meeting #8/01-Perl-oo   47
•                              :-(
•        Perl




070310     Kansai.pm Meeting #8/01-Perl-oo   48
070310   Kansai.pm Meeting #8/01-Perl-oo   49
070310   Kansai.pm Meeting #8/01-Perl-oo   50
Perl                                     …
•
•
•
•
•



070310      Kansai.pm Meeting #8/01-Perl-oo       51
070310   Kansai.pm Meeting #8/01-Perl-oo   52
070310   Kansai.pm Meeting #8/01-Perl-oo   53
070310   Kansai.pm Meeting #8/01-Perl-oo   54

Weitere ähnliche Inhalte

Empfohlen

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by HubspotMarius Sescu
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTExpeed Software
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsPixeldarts
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthThinkNow
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfmarketingartwork
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024Neil Kimberley
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)contently
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024Albert Qian
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsKurio // The Social Media Age(ncy)
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Search Engine Journal
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summarySpeakerHub
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next Tessa Mero
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentLily Ray
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best PracticesVit Horky
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project managementMindGenius
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...RachelPearson36
 

Empfohlen (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

OO language Perl

  • 1. id:lapis25 lapis25@gmail.com Kansai.pm Meeting #8/20070310
  • 2. Larry Wall 070310 Kansai.pm Meeting #8/01-Perl-oo 2
  • 3. 070310 Kansai.pm Meeting #8/01-Perl-oo 3
  • 4.
  • 5. • • • 070310 Kansai.pm Meeting #8/01-Perl-oo 5
  • 6. 070310 Kansai.pm Meeting #8/01-Perl-oo 6
  • 7. 070310 Kansai.pm Meeting #8/01-Perl-oo 7
  • 8. 070310 Kansai.pm Meeting #8/01-Perl-oo 8
  • 9. 070310 Kansai.pm Meeting #8/01-Perl-oo 9
  • 10. 070310 Kansai.pm Meeting #8/01-Perl-oo 10
  • 11. package Class; 070310 Kansai.pm Meeting #8/01-Perl-oo 11
  • 12. 070310 Kansai.pm Meeting #8/01-Perl-oo 12
  • 13. • • 070310 Kansai.pm Meeting #8/01-Perl-oo 13
  • 14. package Class; sub method { # } 070310 Kansai.pm Meeting #8/01-Perl-oo 14
  • 15. $obj_ref->method('args'); Class::method($obj_ref, 'args'); 070310 Kansai.pm Meeting #8/01-Perl-oo 15
  • 16. package Class; sub method { my ($self, @args) = @_; # } 070310 Kansai.pm Meeting #8/01-Perl-oo 16
  • 17. 070310 Kansai.pm Meeting #8/01-Perl-oo 17
  • 18. 070310 Kansai.pm Meeting #8/01-Perl-oo 18
  • 19. 070310 Kansai.pm Meeting #8/01-Perl-oo 19
  • 20. bless $hash_ref, 'Class'; • • 070310 Kansai.pm Meeting #8/01-Perl-oo 20
  • 21. #A bless print ref($hash_ref); $hash_ref #HASH bless $hash_ref, 'Class'; #B bless print ref($hash_ref); Class #Class _id '01' _type 'script' _name 'Perl' 070310 Kansai.pm Meeting #8/01-Perl-oo 21
  • 22. 070310 Kansai.pm Meeting #8/01-Perl-oo 22
  • 23. 070310 Kansai.pm Meeting #8/01-Perl-oo 23
  • 24. 070310 Kansai.pm Meeting #8/01-Perl-oo 24
  • 25. package Class; sub new { my ($class, @args) = @_; return bless { @args }, $class; } 070310 Kansai.pm Meeting #8/01-Perl-oo 25
  • 26. $obj_ref = Class->new( $id, $type ); $obj_ref = Class::new('Class',$id, $type); 070310 Kansai.pm Meeting #8/01-Perl-oo 26
  • 27. • DESTROY • • 070310 Kansai.pm Meeting #8/01-Perl-oo 27
  • 28. 070310 Kansai.pm Meeting #8/01-Perl-oo 28
  • 29. • • • • 070310 Kansai.pm Meeting #8/01-Perl-oo 29
  • 30. 070310 Kansai.pm Meeting #8/01-Perl-oo 30
  • 31. package PerlHacker; use base qw( Programmer Obfuscator ); package Programmer; use base qw( Coder Documenter ); 070310 Kansai.pm Meeting #8/01-Perl-oo 31
  • 32. Coder Documenter use base qw( Coder Documenter ); Programmer Obfuscator use base qw( Programmer Obfuscator ); PerlHacker 070310 Kansai.pm Meeting #8/01-Perl-oo 32
  • 33. Coder Documenter Programmer Obfuscator PerlHacker 070310 Kansai.pm Meeting #8/01-Perl-oo 33
  • 34. 070310 Kansai.pm Meeting #8/01-Perl-oo 34
  • 35. 070310 Kansai.pm Meeting #8/01-Perl-oo 35
  • 36. 070310 Kansai.pm Meeting #8/01-Perl-oo 36
  • 37. 070310 Kansai.pm Meeting #8/01-Perl-oo 37
  • 38. 070310 Kansai.pm Meeting #8/01-Perl-oo 38
  • 39. • • • • • • 070310 Kansai.pm Meeting #8/01-Perl-oo 39
  • 40. 070310 Kansai.pm Meeting #8/01-Perl-oo 40
  • 41. 070310 Kansai.pm Meeting #8/01-Perl-oo 41
  • 42. 070310 Kansai.pm Meeting #8/01-Perl-oo 42
  • 43. 070310 Kansai.pm Meeting #8/01-Perl-oo 43
  • 44. • Class::Accessor(::fast) – • Class::Data::Inheritable – 070310 Kansai.pm Meeting #8/01-Perl-oo 44
  • 45. • NEXT – Catalyst – • Class::C3 – DBIC – C3 NEXT 070310 Kansai.pm Meeting #8/01-Perl-oo 45
  • 46. Class::Std 070310 Kansai.pm Meeting #8/01-Perl-oo 46
  • 47. 070310 Kansai.pm Meeting #8/01-Perl-oo 47
  • 48. :-( • Perl 070310 Kansai.pm Meeting #8/01-Perl-oo 48
  • 49. 070310 Kansai.pm Meeting #8/01-Perl-oo 49
  • 50. 070310 Kansai.pm Meeting #8/01-Perl-oo 50
  • 51. Perl … • • • • • 070310 Kansai.pm Meeting #8/01-Perl-oo 51
  • 52. 070310 Kansai.pm Meeting #8/01-Perl-oo 52
  • 53. 070310 Kansai.pm Meeting #8/01-Perl-oo 53
  • 54. 070310 Kansai.pm Meeting #8/01-Perl-oo 54