Imports System
Imports uCalcSoftware
Public Module Program
   Public Sub Main()
      Dim uc As New uCalc()
      Dim t As New uCalc.Transformer()
      t.Description = "My Main Transformer"
      t.Text = "apple banana apple"
      
      Dim appleRule = t.FromTo("apple", "APPLE")
      Dim bananaRule = t.FromTo("banana", "BANANA")
      
      t.Find()
      
      For Each match In t.Matches
         Dim rule = match.Rule
         Dim parent = rule.ParentTransformer
         Console.WriteLine($"Match '{match.Text}' found by rule '{rule.Name}' in transformer '{parent.Description}'")
      Next
   End Sub
End Module