| B :: XPath. B :: XPath Ŭ·¡½º´Â XPath ±¸¹®À¸·Î Perl Optrees¸¦ °Ë»ö ÇÒ ¼ö ÀÖ½À´Ï´Ù. |
Áö±Ý ´Ù¿î·Îµå |
B :: XPath. ¼øÀ§ ¹× ¿ä¾à
- ƯÇã:
- Perl Artistic License
- °Ô½ÃÀÚ À¥»çÀÌÆ®:
- http://search.cpan.org/~chromatic/Crypt-CipherSaber-1.00/lib/Crypt/CipherSaber.pm
B :: XPath. ű×
B :: XPath. ¼³¸í
B :: XPath Ŭ·¡½º´Â XPath ±¸¹®À¸·Î Perl Optrees¸¦ °Ë»ö ÇÒ ¼ö ÀÖ½À´Ï´Ù. B :: XPath Ŭ·¡½º´Â XPath ±¸¹®À» »ç¿ëÇÏ¿© Perl Optree¸¦ °Ë»ö ÇÒ ¼ö ÀÖ½À´Ï´Ù. SynopsisPerlÀº ÇÁ·Î±×·¥À» opcodesÀÇ Æ®¸®·Î ³»ºÎÀûÀ¸·Î ³ªÅ¸³À´Ï´Ù. ÇÁ·Î±×·¥À» ½ÇÇàÇÏ·Á¸éÀÌ Æ®¸®¸¦ °È°í °¢ ÀÛ¾÷À» ¸¸³ª´Â °Íó·³ ¼öÇàÇÕ´Ï´Ù. B °¡Á· ¸ðµâÀ» »ç¿ëÇϸé run.b :: XPath¿¡¼µµ ÇÁ·Î±×·¥ ¿¡¼ÀÌ optree¸¦ °Ë»ç ÇÒ ¼ö ÀÖ½À´Ï´Ù .B :: XPath´Â XPath ±¸¹®À» »ç¿ëÇÏ¿© Optree¿¡¼ OPS¸¦ ¼±ÅÃÇÒ ¼ö ÀÖ½À´Ï´Ù. B :: XPath¸¦ »ç¿ëÇϽʽÿÀ. ³» $ node = b :: xpath-> fetch_root (some_function); ³» $ root = b :: xpath-> fetch_main_root (); # ¸ðµç ±Û·Î¹ú ½ºÄ®¶ó ã±â ³» @globals = $ root-> match ( '// gvsv'); # $ Bob ³» @bobs = $ node-> match ( '// gvsv '¶ó´Â À̸§ÀÇ ¸ðµç ±Û·Î¹ú ½ºÄ®¶ó ¾×¼¼½º¸¦ ã½À´Ï´Ù. Ŭ·¡½º ¸Þ¼µå´Â ÀÏÄ¡¸¦ ½ÃÀÛÇÏ´Â µ¥ »ç¿ëÇÒ µÎ °¡Áö ¹æ¹ýÀÔ´Ï´Ù. µÑ ´Ù °Ë»ö ÇÒ Æ®¸®ÀÇ ·çÆ®¸¦ ¼³Á¤ÇÕ´Ï´Ù. Bug.fetch_root ($ subref)¸¦ ãÁö ¾Ê´Â ÇÑ,ÀÌ ¸Þ¼Òµå°¡ ¼ºê ·çƾ ÂüÁ¶¿¡ ´ëÇØ optreeÀÇ ·çÆ®¿¡ÀÖ´Â B ::: xpath :: node °´Ã¼¸¦ ¹ÝȯÇÏÁö ¾Ê´Â ÇÑ ¸ÚÁø µµ¿ì¹Ì ¹æ¹ýÀÌ ¾Æ¸¶µµ »ç¿ëÇÏÁö ¾ÊÀ» °ÍÀÔ´Ï´Ù. ÀÌ ³ëµå¿¡¼ ¼öÇàµÇ´Â ¸ðµç ÀÏÄ¡´Â nodes.fetch_main_root () ÀÏÄ¡ÇÏ´Â Optree ÀÇÀÌ ¸Þ¼µå¸¦ ÇÁ·Î±×·¥ÀÇ ·çÆ®¿¡¼ B ::: xpath :: node °´Ã¼¸¦ ¹ÝȯÇÕ´Ï´Ù. ÀÌ°ÍÀ» »ç¿ëÇÏ¿© Àüü ÇÁ·Î±×·¥À» °Ë»öÇÏ·Á¸é (Àû¾îµµ, ÁÖ¾îÁø ¼ºê ·çƾ ¿ÜºÎÀÇ ºÎºÐ) .find_op_class ($ op)´Â B :: OP ¶Ç´Â Descendent °´Ã¼°¡ ÁÖ¾îÁö¸é ÀûÀýÇÑ B :: xpath :: nodeÀÇ À̸§À» ¹ÝȯÇÕ´Ï´Ù. B :: XPath°¡ ÀûÀýÇÏ°Ô Á¶ÀÛ ÇÒ ¼ö ÀÖµµ·Ï ÇØ´ç OP¸¦ °¨½Î´Â µ¥ »ç¿ëÇÒ ÇÏÀ§ Ŭ·¡½º. ¿ä±¸ »çÇ× : ¡¤ Perl.
B :: XPath. °ü·Ã ¼ÒÇÁÆ®¿þ¾î