How `SkipOver` creates 'dead zones' where other rules are not applied.
ID: 1123
See: Introduction, SkipOver
using uCalcSoftware;
var uc = new uCalc();
var t = new uCalc.Transformer();
t.Text = "transform this but (not this) and this";
// A rule to replace the word 'this'
t.FromTo("this", "THAT");
// A rule to ignore any content inside parentheses
t.SkipOver("({content})");
// The 'this' inside the parentheses is protected by the SkipOver rule
Console.WriteLine(t.Transform());
transform THAT but (not this) and THAT using uCalcSoftware; var uc = new uCalc(); var t = new uCalc.Transformer(); t.Text = "transform this but (not this) and this"; // A rule to replace the word 'this' t.FromTo("this", "THAT"); // A rule to ignore any content inside parentheses t.SkipOver("({content})"); // The 'this' inside the parentheses is protected by the SkipOver rule Console.WriteLine(t.Transform());
#include
#include "uCalc.h"
using namespace std;
using namespace uCalcSoftware;
int main() {
uCalc uc;
uCalc::Transformer t;
t.Text("transform this but (not this) and this");
// A rule to replace the word 'this'
t.FromTo("this", "THAT");
// A rule to ignore any content inside parentheses
t.SkipOver("({content})");
// The 'this' inside the parentheses is protected by the SkipOver rule
cout << t.Transform() << endl;
}
transform THAT but (not this) and THAT #include <iostream> #include "uCalc.h" using namespace std; using namespace uCalcSoftware; int main() { uCalc uc; uCalc::Transformer t; t.Text("transform this but (not this) and this"); // A rule to replace the word 'this' t.FromTo("this", "THAT"); // A rule to ignore any content inside parentheses t.SkipOver("({content})"); // The 'this' inside the parentheses is protected by the SkipOver rule cout << t.Transform() << endl; }
Imports System
Imports uCalcSoftware
Public Module Program
Public Sub Main()
Dim uc As New uCalc()
Dim t As New uCalc.Transformer()
t.Text = "transform this but (not this) and this"
'// A rule to replace the word 'this'
t.FromTo("this", "THAT")
'// A rule to ignore any content inside parentheses
t.SkipOver("({content})")
'// The 'this' inside the parentheses is protected by the SkipOver rule
Console.WriteLine(t.Transform())
End Sub
End Module
transform THAT but (not this) and THAT Imports System Imports uCalcSoftware Public Module Program Public Sub Main() Dim uc As New uCalc() Dim t As New uCalc.Transformer() t.Text = "transform this but (not this) and this" '// A rule to replace the word 'this' t.FromTo("this", "THAT") '// A rule to ignore any content inside parentheses t.SkipOver("({content})") '// The 'this' inside the parentheses is protected by the SkipOver rule Console.WriteLine(t.Transform()) End Sub End Module