XSTRING is predefined byte-like ABAP type with variable length. This type ensures dynamic allocation of memory. Its value is a sequence of bytes that equals its hexadecimal value as shows screenshot from ABAP debugger.
ABAP Conversions
Convert structures between various formats.
Escape HTML / XML / JS content or URI / URL in ABAP
ABAP offers predefined function called escape( ) which is available as of SAP_BASIS >= 731.
Whenever you need to convert your data from unescaped to escaped string, you can use this escape function. There are several options which escaped function provides. You can escape HTML, XML, JS, JSON content or its combination, URL and URI links. You can also use escape function for Cross-site scripting as you can see in this link.