static BlockMatch GetMatch(BlockMatch m1, BlockMatch m2) { return(m1 == null ? m2 == null ? null : m2 : m2 == null ? m1 : m1.Match.Index < m2.Match.Index ? m1 : m2); }
public static BlockMatch GetMatch(string input) { if (_regexCollection == null) { BlockMatcher.Setup(); } BlockMatch result = null; foreach (var regex in _regexCollection) { result = BlockMatcher.GetMatch(result, regex.Match(input)); } return(result); }