Basic Key-Value extraction using a colon as an anchor.
ID: 230
using uCalcSoftware;
var uc = new uCalc();
var t = uc.NewTransformer();
// "ID" and ":" are Anchors. "{id}" is the Variable.
t.FromTo("ID: {id}", "Found ID: {id}");
Console.WriteLine(t.Transform("ID: 12345").Text);
Found ID: 12345 using uCalcSoftware; var uc = new uCalc(); var t = uc.NewTransformer(); // "ID" and ":" are Anchors. "{id}" is the Variable. t.FromTo("ID: {id}", "Found ID: {id}"); Console.WriteLine(t.Transform("ID: 12345").Text);
#include
#include "uCalc.h"
using namespace std;
using namespace uCalcSoftware;
int main() {
uCalc uc;
auto t = uc.NewTransformer();
// "ID" and ":" are Anchors. "{id}" is the Variable.
t.FromTo("ID: {id}", "Found ID: {id}");
cout << t.Transform("ID: 12345").Text() << endl;
}
Found ID: 12345 #include <iostream> #include "uCalc.h" using namespace std; using namespace uCalcSoftware; int main() { uCalc uc; auto t = uc.NewTransformer(); // "ID" and ":" are Anchors. "{id}" is the Variable. t.FromTo("ID: {id}", "Found ID: {id}"); cout << t.Transform("ID: 12345").Text() << endl; }
Imports System
Imports uCalcSoftware
Public Module Program
Public Sub Main()
Dim uc As New uCalc()
Dim t = uc.NewTransformer()
'// "ID" and ":" are Anchors. "{id}" is the Variable.
t.FromTo("ID: {id}", "Found ID: {id}")
Console.WriteLine(t.Transform("ID: 12345").Text)
End Sub
End Module
Found ID: 12345 Imports System Imports uCalcSoftware Public Module Program Public Sub Main() Dim uc As New uCalc() Dim t = uc.NewTransformer() '// "ID" and ":" are Anchors. "{id}" is the Variable. t.FromTo("ID: {id}", "Found ID: {id}") Console.WriteLine(t.Transform("ID: 12345").Text) End Sub End Module