/// <summary> /// create a match time captor master pattern /// </summary> /// <param name="innerPatt">the real pattern</param> /// <param name="judger">use this value to implement IMatchTimeJudger</param> /// <returns>the created pattern</returns> public static Patt MatchTimeMaster(Patt innerPatt, MatchTimeJudgerFunc judger) { return P(Peg.MatchTimeMaster(innerPatt.Value, new SimpleMatchTimeJudger(judger))); }
/// <summary> /// create a match time captor master pattern /// </summary> /// <param name="innerPatt">the real pattern</param> /// <param name="preProcess">use this value to implement ICaptor</param> /// <param name="postProcess">use this value to implement ICaptor</param> /// <param name="judger">use this value to implement IMatchTimeJudger</param> /// <returns>the created pattern</returns> public static Patt MatchTimeMaster(Patt innerPatt, CaptorPreProcessFunc preProcess, CaptorPostProcessFunc postProcess, MatchTimeJudgerFunc judger) { return P(Peg.MatchTimeMaster(innerPatt.Value, new SimpleCaptor(preProcess, postProcess), new SimpleMatchTimeJudger(judger))); }
public SimpleMatchTimeJudger(MatchTimeJudgerFunc judger) { m_judger = judger; }