| Verby :: Dispatcher. Verby :: Dispatcher´Â ´Ü°è¸¦ ¼öÇàÇÏ°í ½ÇÇàÇÏ´Â Perl ¸ðµâÀÔ´Ï´Ù. |
Áö±Ý ´Ù¿î·Îµå |
Verby :: Dispatcher. ¼øÀ§ ¹× ¿ä¾à
- ƯÇã:
- Perl Artistic License
- °Ô½ÃÀÚ À̸§:
- Yuval Kogman
- °Ô½ÃÀÚ À¥»çÀÌÆ®:
- http://search.cpan.org/~nobull/
Verby :: Dispatcher. ű×
Verby :: Dispatcher. ¼³¸í
Verby :: Dispatcher´Â ´Ü°è¸¦ ¼öÇàÇÏ°í ½ÇÇàÇÏ´Â Perl ¸ðµâÀÔ´Ï´Ù. Verby :: Dispatcher´Â ´Ü°è¸¦ ¼öÇàÇÏ°í ½ÇÇàÇÏ´Â Perl ¸ðµâÀÔ´Ï´Ù. makefile¿¡ÀÖ´Â °Í°ú °°Àº ÀÏÁ¾ÀÇ ÀÏÁ¾ .Synopsis´Â Verby :: Dispatcher¸¦ »ç¿ëÇÕ´Ï´Ù. verby :: config :: data; # ¶Ç´Â ¹«¾ð°¡°¡ ³» $ C = verby :: config :: data-> new (); # ... "LOGGER"Çʵ尡 ÇÊ¿äÇÕ´Ï´Ù. ³» $ D = VERBY :: Dispatcher-> New; $ d-> config_hub ($ c); $ d-> add_steps (@steps); $ d-> do_all; methodsNew´Â »õ·Î¿î verby :: dispatcher¸¦ ½ÃÀÛÇÕ´Ï´Ù. duh! add_steps * @ stepdd add_step * @ stepmadd verby :: step¿¡¼ ¹Ýȯ µÈ "depends"¿¡¼ ¹Ýȯ µÈ ¿©·¯ ´Ü°è´Â ¿©±â¿¡ Àç±Í ÀûÀ¸·Î Áý°èµÇ¾î ¹èÄ¡¿¡ Ãß°¡µË´Ï´Ù. algorithm :: Á¾¼Ó¼º :: °³Ã¼, Onder.dep_Engine_ClasSthe Ŭ·¡½º¿¡¼ DependEcy Resolver¸¦ ÀνºÅϽºÈÇÏ´Â µ¥ »ç¿ëµË´Ï´Ù. ±âº»°ªÀº ¾Ë°í¸®Áò :: Á¾¼Ó¼º :: °´Ã¼ :: Á¤·ÄµÇ¾ú½À´Ï´Ù. Subclass it.config_hub? $ new_config_huba setter g verby :: config :: µ¥ÀÌÅÍ (¶Ç´Â ȣȯ °¡´É) °´Ã¼°¡ Àü¿ª ÄÁÅؽºÆ®¸¦ ÆÄ»ý½Ãų °ÍÀÔ´Ï´Ù. dispatcher.IF "config_hub".is_running $ stephwhether¿¡¼ $ stepwhether°¡ ÇöÀç ½ÇÇàÁßÀÎ °ÍÀÔ´Ï´Ù. $ ´Ü°è´Â ÇöÀç ½ÇÇàÁßÀÎ °ÍÀÔ´Ï´Ù. óÀ½ºÎÅÍ). get_cxt $ stePreturns $ ´Ü°è¿Í °ü·ÃµÈ ÄÁÅؽºÆ®¸¦ ¼öÇàÇÕ´Ï´Ù. ÀÌ´Â $ ´Ü°è°¡ µ¥ÀÌÅ͸¦ ÀÛ¼ºÇÒ °ÍÀÔ´Ï´Ù. get_derivable_cxts $ step.IF $ ´Ü°è¿¡ ´ëÇÑ ÄÁÅؽºÆ®¸¦ ¸¸µé ¶§ ÄÁÅؽºÆ®°¡ »õ ÄÁÅؽºÆ®¸¦ ½ÃÀÛÇÕ´Ï´Ù (´Ü°è¿¡¼ "exply_cxt"°¡ true) ½ÃÀ۵˴ϴÙ. , get_parent_cxts ($ ´Ü°è)¿¡¼ ÆÄ»ýµÇ¾ú½À´Ï´Ù. ±×·¸Áö ¾ÊÀ¸¸é get_parent_cxts ($ ´Ü°è)¸¦ ¹ÝȯÇÕ´Ï´Ù. ´Ü°è '°¡ ÄÁÅؽºÆ®¸¦ Á¦°ø ÇÒ ¶§'ÀÌ°ÍÀº ½ÇÁ¦·Î »õ·Î¿î ÄÁÅؽºÆ®°¡ ¸¸µé¾îÁö°í,ÀÌ ÄÁÅؽºÆ®´Â ´Ü°è ¹× it.get_parent_cxts $ stepif¿¡ ÀÇÁ¸ÇÏ´Â ¸ðµç ´Ü°è¸¦ ÀǹÌÇÕ´Ï´Ù. $ ´Ü°è´Â ´Ù¸¥ ´Ü°è¿¡ µû¶ó ´Ù¸£¸ç »óȲÀ» ÅÃÇÕ´Ï´Ù. ±×·¸Áö ¾ÊÀ¸¸é Àü¿ª context.start_step $ stepif ´Ü°è¸¦ ¹ÝȯÇÕ´Ï´Ù. Stepif ´Ü°è´Â ºñµ¿±â ÀÎÅÍÆäÀ̽º¸¦ Áö¿øÇÏ°í ½ÃÀÛÇÏ°í ½ÇÇàÁßÀÎ ½ºÅÜ ´ë±â¿¿¡ ³Ö½À´Ï´Ù. ±×°ÍÀÌ µ¿È°¡µÇ¸é ´Ü°è ¹æ¹ý¿¡¼ "DO"¶ó°í ºÎ¸£¸ç, STEPFINISH ´Ü°è¿¡¼ STEPFINISH ´Ü°è¸¦ Ç¥½ÃÇÏ°í ¸¸Á·½º·¯¿î °ÍÀ¸·Î Ç¥½ÃÇϽʽÿÀ. ºñµ¿±â ´Ü°è¿¡¼¸¸ Èçµé¸®´Â ´ë±â¿ÀÇ $ stepput $ ´Ü°è¸¦ ¼öÇàÇÏ°í ½ÇÇàÁßÀÎ ´Ü°è set.push_running $ steppush $ ´Ü°è¸¦ ½ÇÇàÁßÀÎ ´Ü°è queue.pop_runningpopÀ¸·Î Ç¥½ÃÇÕ´Ï´Ù. justing queue.mk_dep_enginecropÀ» »ç¿ëÇÏ¿© »õ °´Ã¼¸¦ ½ÇÇàÇÕ´Ï´Ù. "DEP_ENGINE_CLASS".INDERED_STEPSRSERNÀº ORDER.PUMP_RUNNALLYGIVE·Î ½ÇÇàµÇ´Â ´Ü°è¸¦ ¼öÇàÇÏ´Â ´Ü°è¸¦ Àü´ÞÇÏ´Â µ¥ ºñÆ®¸¦ Àü´ÞÇÕ´Ï´Ù.ÀÌ ¹æ¹ýÀº IPC :: RUN.ITÀÇ "ÆßÇÁ"¿Í ºñ½ÁÇÕ´Ï´Ù. false.StepsReturns Dispatcher°¡ view.step_setReturns¿¡ ´ëÇØ °ÆÁ¤ÇÏ´Â ´Ü°è ¸ñ·ÏÀÔ´Ï´Ù. running_steps´Â ÇöÀç wranning_setReturns¸¦ ÃßÀûÇÏ´Â µ¥ »ç¿ëµÇ´Â set :: object¸¦ ½ÇÇàÇÕ´Ï´Ù. ¾î¶² ´Ü°è°¡ ½ÇÇàÁßÀÎ ´Ü°èÀÔ´Ï´Ù. atisfied_setReurns.wait_oneeeeffectially finish_step (pop_running) .wait_specific $ stepwai¸¦ ¿Ï·áÇÏ´Â ¸ðµç ½ÇÇàÁßÀÎ ´Ü°è¿¡ ´ëÇØ ¸¸Á·½º·¯¿î ´Ü°è¸¦ ÃßÀûÇÏ´Â µ¥ »ç¿ëµÇ´Â SET :: Object¸¦ ÃßÀûÇÏ´Â µ¥ »ç¿ëµË´Ï´Ù. ƯÁ¤ ´Ü°è¸¦ ¸¶¹«¸®ÇÏ´Â ´Ü°è. ´Ü°è°¡ ÁغñµÇ¾úÀ½À» ÁÖÀåÇϸé ÆßÇÁ _Running¿¡ ÀÇÇØ È£ÃâµË´Ï´Ù. ¿ä±¸ »çÇ× : ¡¤ Perl.
Verby :: Dispatcher. °ü·Ã ¼ÒÇÁÆ®¿þ¾î