コード例 #1
0
        public void Blah()
        {
            var grok = new Grok();

            grok.AddPattern("USERNAME", "[a-z]+");
            grok.AddPattern("HENLOG", "%{USERNAME:user};");

            grok.Compile("%{HENLOG:mylog}");
            var match = grok.Match("aaaaa;");

            match.Should().NotBeNull();

            var captures = match.Captures;
        }