Recursive template engine with escaping and lazy evaluation. Note that it is case SENSITIVE.
Use
1. Add items to templater's map.
templater.map()["bob"] = "joe";
2. Evaluate a text item that references a map item.
s = templater.eval("well, hello [!bob]");
2. Evaluate a text item that references a map item.
s = templater.eval("well, hello [!bob]");
Returns "well, hello joe" in s;
Code
templater.h
evaluator.h
evaluator.cpp
Code
templater.h
evaluator.h
evaluator.cpp
2 comments:
templater.h and evaluator.cpp are currently inaccessible.
Thanks for the heads up. I fixed the links, they work now. ;)
Thank you!
Post a Comment