diff --git a/AnovSyntax/Anov.cs b/AnovSyntax/Anov.cs index e963ed0..e137827 100644 --- a/AnovSyntax/Anov.cs +++ b/AnovSyntax/Anov.cs @@ -12,10 +12,40 @@ public static void Read(string str) { Match match; - // Read "- people-name" - match = Regex.Match(str, @"- (.*)"); + // Unsupported + // Read "> place" + match = Regex.Match(str, @"> (.*)"); + if (match.Success) + Console.WriteLine(""); + + // Unsupported + // Read "bgm: background-music" + match = Regex.Match(str, @"bgm: (.*)"); + if (match.Success) + Console.WriteLine(""); + + // Unsupported + // Read "movie: movie" + match = Regex.Match(str, @"movie: (.*)"); + if (match.Success) + Console.WriteLine(""); + + // Read "- people-name / emotion" + match = Regex.Match(str, @"- (.*?)/"); if (match.Success) Console.Write(match.Groups[1].Value.Trim()); + else + { + // Read "- people-name" + match = Regex.Match(str, @"- (.*)"); + if (match.Success) + Console.Write(match.Groups[1].Value.Trim()); + } + + // Read "/ emotion" + match = Regex.Match(str, @"/ (.*)"); + if (match.Success) + Console.Write(" (" + match.Groups[1].Value.Trim() + ")"); // Read "[conversatioc-content]" match = Regex.Match(str, @"\[(.*?)\]"); diff --git a/Sample/sample.anov b/Sample/sample.anov index cb56a7e..cec444d 100644 --- a/Sample/sample.anov +++ b/Sample/sample.anov @@ -1,4 +1,4 @@ -- Alice +- Alice / happy [Hello everyone!!] - Bob