コード例 #1
0
        private void GetMatchInfo <T>(string record, RegexOutput <T> data)
            where T : new()
        {
            var mc = data.Expression.Matches(record);

            SelectMatches.GetMatchValues(mc, data);
        }
コード例 #2
0
        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);
        }
コード例 #3
0
        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);
        }
コード例 #4
0
        private void GetMatchInfo(string record, RegexOutput data)
        {
            var mc = data.Expression.Matches(record);

            SelectMatches.GetMatchValues(mc, data);
        }