(textToEncode: string)
| 84 | } |
| 85 | |
| 86 | function createXmlEncodeMethods(textToEncode: string) { |
| 87 | const nonAsciiPrintable: EncodeOptions = {level: 'xml', mode: 'nonAsciiPrintable'}; |
| 88 | const extensive: EncodeOptions = {level: 'xml', mode: 'extensive'}; |
| 89 | const nonAscii: EncodeOptions = {level: 'xml', mode: 'nonAscii'}; |
| 90 | return { |
| 91 | 'html-entities.encode - xml, nonAscii': () => encode(textToEncode, nonAscii), |
| 92 | 'html-entities.encode - xml, nonAsciiPrintable': () => encode(textToEncode, nonAsciiPrintable), |
| 93 | 'html-entities.encode - xml, extensive': () => encode(textToEncode, extensive), |
| 94 | '(old) XmlEntities.encodeNonASCII': () => xmlEntities.encode(textToEncode), |
| 95 | 'entities.encodeXML': () => entities.encodeXML(textToEncode) |
| 96 | }; |
| 97 | } |
| 98 | |
| 99 | function createXmlDecodeMethods(textToDecode: string) { |
| 100 | const strict: DecodeOptions = {level: 'xml', scope: 'strict'}; |
no test coverage detected