MCPcopy Create free account
hub / github.com/ronreiter/interactive-tutorials / escape

Method escape

suds/sax/text.py:49–59  ·  view source on GitHub ↗

Encode (escape) special XML characters. @return: The text with XML special characters escaped. @rtype: L{Text}

(self)

Source from the content-addressed store, hash-verified

47 return result
48
49 def escape(self):
50 """
51 Encode (escape) special XML characters.
52 @return: The text with XML special characters escaped.
53 @rtype: L{Text}
54 """
55 if not self.escaped:
56 post = sax.encoder.encode(self)
57 escaped = post != self
58 return Text(post, lang=self.lang, escaped=escaped)
59 return self
60
61 def unescape(self):
62 """

Callers

nothing calls this directly

Calls 2

TextClass · 0.85
encodeMethod · 0.45

Tested by

no test coverage detected