| Pixie :: Complicity. Pixie :: Complicity´Â ÀÏÀ» Pixie¿Í Àß ¿¬ÁÖÇÏ´Â Perl ¸ðµâÀÔ´Ï´Ù. |
Áö±Ý ´Ù¿î·Îµå |
Pixie :: Complicity. ¼øÀ§ ¹× ¿ä¾à
- ƯÇã:
- Perl Artistic License
- °Ô½ÃÀÚ À̸§:
- James A Duncan
- °Ô½ÃÀÚ À¥»çÀÌÆ®:
- http://search.cpan.org/~jduncan/Pixie-2.06/lib/Pixie/Complicity.pm
Pixie :: Complicity. ű×
Pixie :: Complicity. ¼³¸í
Pixie :: Complicity´Â Perl ¸ðµâÀ̸ç Pixie¿Í Àß Àç»ýµÇ´Â Perl ¸ðµâÀÔ´Ï´Ù. Pixie :: Complicity´Â Pixie.Rationale¿¡¼ ÀÏÀ» Àß Àç»ýÇÒ ¼öÀÖ´Â Perl ¸ðµâÀÔ´Ï´Ù. ¸¹Àº °´Ã¼ÀÇ °æ¿ì Pixie´Â °´Ã¼ÀÇ Å¬·¡½ºÀÇ µµ¿òÀÌ ÇÊ¿äÇÏÁö ¾Ê°í °´Ã¼¸¦ Åõ¸íÇÏ°Ô ÀúÀåÇÒ ¼ö ÀÖ½À´Ï´Ù. ±×·¯³ª ¶§·Î´Â ±×·¸Áö ¾ÊÀº °æ¿ì°¡ ÀÖ½À´Ï´Ù. XS¸¦ »ç¿ëÇÏ¿© ±¸Çö µÈ Ŭ·¡½ºÀÇ °æ¿ì, Perl¿¡¼ ¾×¼¼½º ÇÒ ¼ö¾ø´Â ÀϺΠC ±¸Á¶¿¡¼ µ¥ÀÌÅ͸¦ ÀúÀåÇϴ Ŭ·¡½ºÀÇ °æ¿ì °¡Àå ÀϹÝÀûÀ¸·Î. ¹®Á¦ÀÇ Å¬·¡½ºÀÇ °øÆò¼º¾øÀÌ ±×·¯ÇÑ Á¤º¸¸¦ ¾ò´Â °ÍÀº ÇȼÒÆ®°¡ ¹Îº´´ë ÀÎ ÅÚ·¹ÆĽà (Telepathic)¿Í ¸¶Âù°¡Áö·Î Çȼҽº°¡ ÇÊ¿äÇÕ´Ï´Ù. ±×¸®°í ±×°ÍÀº ¾ðÁ¦µçÁö ÀϾ ÀÏÀÌ ¾Æ´Õ´Ï´Ù. ±×´Â °´Ã¼¸¦ ÀúÀåÇÏ°í °¡Á® ¿À´Â °úÁ¤¿¡¼ Pixie°¡ »ç¿ëÇÏ´Â À¯´Ï¹ö¼È¿¡¼ ÀÏ·ÃÀÇ ¹æ¹ýÀ» Á¦°øÇÕ´Ï´Ù. ´ç½ÅÀÌÇØ¾ß ÇÒ ÀÏÀº ÇØ´ç ¼ö¾÷¿¡¼ ¸î °¡Áö¸¦ ¹«½ÃÇÏ´Â °ÍÀÔ´Ï´Ù. (CPAN¿¡¼ Ŭ·¡½º¸¦ »ç¿ëÇÏ°í ÀÖ´õ¶óµµ Ŭ·¡½ºÀÇ ½Éº¼ Å×À̺íÀÌ Ç×»ó ¿·Á ÀÖÀ¸¹Ç·Î ÇïÆÛ ¸Þ¼µå¸¦ ¼ÓÀÌ°í Ãß°¡ ÇÒ ¼ö ÀÖÀ¸¹Ç·Î ¸Þ¼Òµå ³×ÀÓ ½ºÆäÀ̽º (¸ðµç ¸Þ¼Òµå°¡ PX_·Î ½ÃÀÛ)¸¦ ¼±ÅÃÇß½À´Ï´Ù. Wild.ExampleConsider¿¡¼ ¹ÛÀ¸·ÎÀִ Ŭ·¡½º¿Í ÇÔ²² Ãæµ¹ÇÏÁö ¾Ê½À´Ï´Ù. set :: object Ŭ·¡½º. ±â´ëÇÏ´Â ¸ðµç ÀÛ¾÷À» ÅëÇØ Áñ°Ì°Ô ºü¸¥ ¼¼Æ®¸¦ ±¸ÇöÇÏ´Â ¸Å¿ì »ç¶û½º·¯¿î Ŭ·¡½ºÀÔ´Ï´Ù. ±×·¯³ª ¼ø¼´ë·Î ¼Óµµ¸¦ ¾òÀ¸·Á¸é XS¸¦ »ç¿ëÇÏ¿© ±¸ÇöµÇ¾úÀ¸¸ç µ¥ÀÌÅÍ :: Dumper°¡ º¸ÀÌ´Â ºÎºÐÀº ´Ü¼øÈ÷ ½ºÄ®¶ó ÂüÁ¶ ÀÏ»ÓÀÔ´Ï´Ù. µû¶ó¼ ÇÁ·ÎÁ§Æ® (±×¸®°í ¿ì¸®´Â ¼öÇà)¿¡¼ Set :: °´Ã¼¸¦ »ç¿ëÇÏ°íÀÚÇÏ´Â °æ¿ì Pixie.so¿Í ¿Ï¼º ÇØÁý´Ï´Ù. ¸ÕÀú Pixie°¡ ÀúÀå °¡´ÉÇÑ °ÍÀÓÀ» ¾Ë°í ÀÖ´ÂÁö È®ÀÎÇϽʽÿÀ. Sub Set :: Object :: px_is_storable {1} ¿ì¸®´Â ¿ì¸®°¡ ¾î¶»°Ô ÀúÀå °¡´ÉÇÑ °ÍÀ» ·»´õ¸µ ÇÒ °ÍÀÎÁö¿¡ ´ëÇØ ¾î¶»°Ô »ý°¢ÇÕ´Ï´Ù. ¿ì¸®ÀÇ ¸ñÀûÀ» À§ÇØ, ȸ¿ø ¸ñ·Ï (±×¸®°í ´ç½ÅÀº ¹«¾ùÀ» ¾Ë°í ÀÖ´ÂÁö, ´ÙÀ½À» ¾Ë°íÀÖ´Â °ÍÀÔ´Ï´Ù. e 'memento'ÆÐÅÏÀ» »ç¿ëÇÕ´Ï´Ù. ¾ÆÀ̵ð¾î´Â ÇØ´ç °´Ã¼¿¡ ´ëÇÑ °´Ã¼¿¡ ´ëÇÑ °´Ã¼¿¡ ´ëÇÑ ÃæºÐÇÑ Á¤º¸¸¦ ÀúÀåÇÒ ÃæºÐÇÑ Á¤º¸¸¦ ³ªÁß¿¡ Àç»ýÇÒ ¼öÀÖ´Â Memento °´Ã¼¸¦ ¸¸µå´Â °ÍÀÔ´Ï´Ù. SET :: ObjectÀÇ px_freeze ¸Þ¼µå¸¦ ¼³Á¤ÇÏ¿© ÇØ´ç memento¸¦ ¸¸µì´Ï´Ù. sub set :: object :: px_freeze {my $ self = shift; ¹Ýȯ , 'memento :: set :: Object'; }½¬¿î. ¿ì¸®ÀÇ ´ÙÀ½ Æ®¸¯À» À§ÇØ, ¿ì¸®´Â ±â¹Ì°¡ ¹°Ã¼·Î µÇµ¹¾Æ °¡°ÔµÇµµ·Ï ¾î¶² ¹æ¹ýÀ» Á¦°øÇؾßÇÕ´Ï´Ù. Pixie´Â µ¥ÀÌÅÍ ÀúÀå¼Ò¿¡¼ °Ë»öÇÏ´Â ¸ðµç °´Ã¼¿¡¼ px_thaw¸¦ È£ÃâÇϵµ·Ï º¸ÀåÇϹǷΠMemento Ŭ·¡½º¿¡¼ ÇØ´ç PX_THAW ¸Þ¼Òµå¸¦ ±¸ÇöÇÏ´Â °ÍÀÔ´Ï´Ù. Sub memento :: set :: Object :: px_thaw {My $ self = shift; ¹Ýȯ ¼³Á¤ :: °³Ã¼ -> »õ (@ $ self); } ±×¸®°í ¸¶¹ý¿¡ ÀÇÇÑ °Íó·³, ¼³Á¤ :: °´Ã¼´Â ÀÌÁ¦ ´ç½ÅÀÇ pixie¿¡¼ ÇູÇÏ°Ô Áö¼ÓµÉ ¼ö ÀÖ½À´Ï´Ù. ¿ä±¸ »çÇ× : ¡¤ Perl.
Pixie :: Complicity. °ü·Ã ¼ÒÇÁÆ®¿þ¾î