private void GetMatchInfo <T>(string record, RegexOutput <T> data) where T : new() { var mc = data.Expression.Matches(record); SelectMatches.GetMatchValues(mc, data); }
public static RegexOutput InitializeOutput(Regex expressionToUse) { RegexOutput output = new RegexOutput { Expression = expressionToUse, MatchCollection = new List <MatchCollection>(), Groups = new List <Group>(), GroupNames = expressionToUse.GetGroupNamesWithoutZero(), AllMatchedNamedGroupValues = new Dictionary <string, List <string> >() }; return(output); }
public static RegexOutput <T> InitializeOutput <T>(T classToFill, Regex expressionToUse) { RegexOutput <T> output = new RegexOutput <T> { Expression = expressionToUse, MatchCollection = new List <MatchCollection>(), Groups = new List <Group>(), GroupNames = expressionToUse.GetGroupNamesWithoutZero(), AllMatchedNamedGroupValues = new Dictionary <string, List <NamedMatchGroupValues> >(), UserProvidedModel = new List <T>() }; return(output); }
private void GetMatchInfo(string record, RegexOutput data) { var mc = data.Expression.Matches(record); SelectMatches.GetMatchValues(mc, data); }