ÇÏÀ§ :: ¼³Ä¡

SUB :: ¼³Ä¡ ¸ðµâÀ» »ç¿ëÇÏ¸é ¼­ºê ·çƾÀ» ½±°Ô ÆÐÅ°Áö¿¡ ¼³Ä¡ÇÒ ¼ö ÀÖ½À´Ï´Ù.
Áö±Ý ´Ù¿î·Îµå

ÇÏÀ§ :: ¼³Ä¡ ¼øÀ§ ¹× ¿ä¾à

±¤°í

  • Rating:
  • ƯÇã:
  • Perl Artistic License
  • °¡°Ý:
  • FREE
  • °Ô½ÃÀÚ À̸§:
  • Ricardo Signes
  • °Ô½ÃÀÚ À¥»çÀÌÆ®:
  • http://search.cpan.org/~rjbs/

ÇÏÀ§ :: ¼³Ä¡ ű×


ÇÏÀ§ :: ¼³Ä¡ ¼³¸í

SUB :: ¼³Ä¡ ¸ðµâÀ» »ç¿ëÇÏ¸é ¼­ºê ·çƾÀ» ÆÐÅ°Áö¿¡ ½±°Ô ¼³Ä¡ÇÒ ¼ö ÀÖ½À´Ï´Ù. SUB :: ¼³Ä¡ ¸ðµâÀ» »ç¿ëÇϸé ÆÐÅ°Áö¿¡ ¼­ºê ·çƾÀ» ¼³Ä¡ÇÒ ¼ö ÀÖ½À´Ï´Ù. SYNOPSIS »ç¿ë ÇÏÀ§ :: ¼³Ä¡; ÇÏÀ§ :: ¼³Ä¡ :: install_sub ({code => sub {...}, => $ package, as => $ subname});ÀÌ ¸ðµâÀº ¾ö°ÝÇÑ ¾û¸ÁÀ̾ø´Â ¾û¸ÁÀ̾ø´Â ÆÐÅ°Áö¿¡ ¼­ºê ·çƾÀ» ½±°Ô ¼³Ä¡ÇÒ ¼ö ÀÖ½À´Ï´Ù. ¶Ç´Â ´©±¸³ª º¼ ¼öÀÖ´Â À§Ä¡¿¡ ´ëÇØ ´©¿öÀÖ´Â TypegLobs .FunctionsInstall_sub ÇÏÀ§ :: ¼³Ä¡ :: install_sub ({code => subroutine, => "finance :: shady", => 'launder', => "subroutine));ÀÌ ·çƾÀº ÀÏ¹Ý ¼­ºê ·çƾÀ¸·Î ÆÐÅ°Áö¿¡ Äڵ带 ÂüÁ¶ÇϽʽÿÀ. À§ÀÇ »çÇ×Àº ´ÙÀ½°ú °°½À´Ï´Ù. ¾ö°ÝÇÑ '½ÉÆÇ'; * { "Finance :: Shady". '::'. "Launder"} = If IN SUB°¡ È£Ãâ ÆÐÅ°Áö¿¡ ¼³Ä¡µÇ¾î ÀÖÁö ¾Ê½À´Ï´Ù. ÄÚµå´Â ÄÚµå ÂüÁ¶°¡ ¾Æ´Ï¸ç, ¿©±â¿¡¼­´Â FROM ¸Å°³ º¯¼ö¿¡ ¸í¸í µÈ ÆÐÅ°ÁöÀÇ ±âÁ¸ ÇÏÀ§·Î Ç¥½ÃµË´Ï´Ù. ºÎÅÍ°¡ ÁÖ¾îÁöÁö ¾ÊÀ¸¸é È£Ãâ ÆÐÅ°Áö¸¦ ã½À´Ï´Ù. ÁÖ¾îÁø °Íó·³ Äڵ尡 ÁöÁ¤µÇÁö ¾ÊÀº °æ¿ì Äڵ尡 ±âº»°ªÀ¸·Î Ç¥½ÃµË´Ï´Ù. ±×·¸Áö¸¸ Äڵ尡 ÄÚµå ref ÀÎ °æ¿ì sub :: installÀº ÁÖ¾îÁø ÄÚµå refÀÇ À̸§À» ã¾Æ À̽´¸¦ »ç¿ëÇÏ·Á°í ½ÃµµÇÕ´Ï´Ù.ÀÌ ÄÚµå´Â ´ÙÀ½ ÄÚµå °¡ÀÌ Äڵ带 ÀǹÌÇÕ´Ï´Ù. sub :: install :: install_sub ({ => 'person :: inpain'¿¡¼­ => 'person :: teenager', => 'dance',}};¿¡¼­ => 'person :: inpain'¿¡¼­ => 'person :: teenager', Package Person :: Teenager; SUB :: install :: install_sub ({code => person :: inpain-> can ( 'twitch'), as => 'dance',}; reinstall_subthis ·çƾÀº "install_sub"¿Í Á¤È®È÷ µ¿ÀÛÇÏÁö¸¸ °æ°í¸¦ ¹æÃâÇÏÁö ¾Ê½À´Ï´Ù. °æ°í°¡ ÄÑÁ® ÀÖ°í ´ë»óÀÌ ÀÌ¹Ì Á¤ÀǵǾîÀÖ´Â °æ¿ì SUB :: ¼³Ä¡ ÇÁ·Î±×·¥°úÀÇ ÇÏÀ§ :: ¼³Ä¡ ȣȯ¼ºÀ» Çã¿ëÇϱâ À§ÇØ install_installersthis ·çƾÀÌ Á¦°øµË´Ï´Ù. install_sub ¹× rentallstal_sub ¸Þ¼Òµå¸¦ Àμö·Î ÁöÁ¤µÈ ÆÐÅ°Áö¿¡ ¼³Ä¡ÇÕ´Ï´Ù. ÇÏÀ§ :: ¼³Ä¡ :: install_installers ( 'code :: Builder'); # ¿ì¸®¸¦ À§ÇØ, ÄÚµå :: Builder-> install_sub ({name => $ code_ref}); ÇÏÀ§ :: ¼³Ä¡ :: install_installers ( 'Universal'); # ¿îÀÌ ÁÁ°í ÆãÅ© ´À³¦? Anything :: AT :: ALL-> install_sub ({name => $ code_ref}); ¼³Ä¡µÈ ¼³Ä¡ ÇÁ·Î±×·¥Àº Sub :: ¼³Ä¡ ÇÁ·Î±×·¥¿¡¼­ Á¦°øÇÏ´Â °ÍµéÀÌ Á¦°ø ÇÑ °Í°ú µ¿ÀÏÇÏÁö¸¸ µ¿ÀÏÇÏÁö´Â ¾Ê½À´Ï´Ù. ±×µéÀº ´ÜÀÏ Çؽø¦ ³íÀïÀ¸·Î ¹Þ¾ÆµéÀÔ´Ï´Ù. Å° / °ª ½ÖÀº À§¿¡ ¼³¸í µÈ install_sub ·çƾ¿¡ ´ëÇÑ AS ¹× ÄÚµå ¸Å°³ º¯¼ö·Î »ç¿ëµË´Ï´Ù. ¸Þ¼Òµå°¡ È£ÃâµÇ´Â ÆÐÅ°Áö À̸§Àº into ¸Å°³ º¯¼ö·Î »ç¿ëµË´Ï´Ù .unlike sub :: installerÀÇ install_sub´Â Äڵ忡 evalÀÌ ¾Æ´ÏÁö¸¸ È£Ãâ ÆÐÅ°Áö¿¡¼­ ¸í¸í µÈ Äڵ带 ã½À´Ï´Ù. ¿ä±¸ »çÇ× : ¡¤ Perl.


ÇÏÀ§ :: ¼³Ä¡ °ü·Ã ¼ÒÇÁÆ®¿þ¾î