anek77713 has asked for the wisdom of the Perl Monks concerning the following question:

Can someone give me a hint?

What should I read to learn building modules over existing ones?

Replies are listed 'Best First'.
Re: Building Perl Modules
by kcott (Archbishop) on Jul 23, 2013 at 09:27 UTC

    G'day anek77713,

    "Can someone give me a hint?"

    One of the first tools I reach for when seeking Perl information is Perldoc. This is available online from http://perldoc.perl.org/perl.html (I recommend you bookmark this) and as the commandline utility perldoc.

    "What should I read to learn building modules over existing ones?"

    This is very vague: "building" (writing? creating? other?); "over" (on top of/replacing? instead of? subclassing? other?); "existing" (builtin? CPAN? in-house? other?).

    Under the Reference Manual section of the link I provided above, you'll find a block of six links whose descriptions all start with "Perl modules:":

    One or more of those may well provide the information you're looking for. If not, please ask a more specific question.

    -- Ken

      Thnx for the answer!!!!

      The problem is:

      Module : Pod::PseudoPod::HTML

      I wish to write a module... That will be:

      Pod::PseudoPod::HTML::Book

      But I can't understand how to make this...

      How to link the content of Book to the Pod::PseudoPod::HTML to use the code from up the tree

        Many (probably most) documentation pages have a SEE ALSO section which provides links to related documentation. The first "Perl module: ..." link I provided above ("perlmod Perl modules: how they work") has a link to perlootut - Object-Oriented Programming in Perl Tutorial. (It sounds like a tutorial is what you need.) Within that documentation, you'll find the answer to your question:

        "Inheritance lets you create a specialized version of an existing class. Inheritance lets the new class reuse the methods and attributes of another class. ..."

        -- Ken

        use strict; use warnings; package Pod::PseudoPod::HTML::Book; use base 'Pod::PseudoPod::HTML'; # ... your code goes here ... 1;
        package Cow { use Moo; has name => (is => 'lazy', default => sub { 'Mooington' }) } say Cow->new->name
Re: Building Perl Modules
by Anonymous Monk on Jul 23, 2013 at 07:39 UTC
Re: Building Perl Modules
by mtmcc (Hermit) on Jul 23, 2013 at 07:42 UTC
    This might be useful.