using uCalcSoftware; var uc = new uCalc(); var t = new uCalc.Transformer(); t.FromTo("Log [ERROR] entry", "MATCHED"); // This matches because the optional word is present Console.WriteLine(t.Transform("Log ERROR entry found.")); // This also matches because the word is optional Console.WriteLine(t.Transform("Log entry found."));