Others have answered the "what". Here is the where.
__PACKAGE__ is defined in perldata.
After you understand that __PACKAGE__ will be replaced
with the current package, the workings of the method
call are described in perlobj and elsewhere.
To discover this yourself, along with the other references
to __PACKAGE__, try:
perldoc -l perl
to find what directory perl.pod is in, cd to that directory,
and then grep for __PACKAGE__.
UPDATE
Oops. Kanji pointed out that his post did answer the
where. But the idea of using grep is still worth knowing
about as a way to find these things out when you don't
know where to look first.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.