toXML method

  1. @override
String toXML()
override

Implementation

@override
String toXML() {
  return '''
  <?xml version="1.0" encoding="utf-8"?>
  <cupps xmlns="$xmlns" messageID="$messageID" xmlns:xsi="$xsi" messageName="$messageName">
      <notify>
          <illogicalMessageErrorEvent applicationName="$applicationName"
          applicationVersion="$applicationVersion" user="$user" workstation="$workstation">
              <illogicalMessage>
                  $illogicalMessage
              </illogicalMessage>
              <expectedMessageNameList>
                  ${expectedMessageNameList.map((e) => '<messageName messageName="$e"/>').join()}
              </expectedMessageNameList>
          </illogicalMessageErrorEvent>
      </notify>
  </cupps>
  '''
      .replaceAll("\n", "")
      .replaceAll("\t", "")
      .replaceAll("  ", "");
}