gopicsw / simdesign

Automatically exported from code.google.com/p/simdesign
0 stars 1 forks source link

Add WriteEscapedString to TXMLNode or... #9

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Hello,

Bit of background. If I have some misbehaving system that do not like some 
characters (in other words badly made). Like Nordic ones äöå.

Now I can't (Or I could not find) write string that I have already handled with 
some escaping routine. because it becomes something like this : ä -> ä -> 
ä

Or other way would be (But would slow things down) to have check at the 
sdEscapeString part which handles the  '&': would check is that part of escaped 
string. I think this would be so much slower to do.

But having Setter in XML node that would bypass the sdEscapeString and will not 
do any Base64 encoding and so on. then user has to make sure that string is 
correctly escaped. Also it could speed thigs little if you are inserting purely 
numeric values and so, when you can be sure that there is no need for escaping.

-Tee-

Original issue reported on code.google.com by tommi.prami@gmail.com on 3 Mar 2014 at 12:24