{"title":"Codeunit 1235 XML Buffer Writer, extension points 29","url":"https://jonas-paprotka.de/ref/codeunit/1235-xml-buffer-writer/points/","author":"JOP-AL","license":"Metadata from Microsoft's symbol packages. AL source MIT, Copyright (c) Microsoft Corporation. Selection and wording © 2026 JOP-AL. https://jonas-paprotka.de/licenses/","subject":"Microsoft Dynamics 365 Business Central","checked":"2026-11-20","changed":"2026-10-05","object":{"type":"codeunit","id":1235,"name":"XML Buffer Writer","app":"Base Application","url":"https://jonas-paprotka.de/ref/codeunit/1235-xml-buffer-writer/"},"major":29,"source":{"url":"https://jonas-paprotka.de/ref/codeunit/1235-xml-buffer-writer/source/","path":"src/Layers/W1/BaseApp/System/DataExchange/XMLBufferWriter.Codeunit.al","commit":"4303e5e584d3aa5d9e98cbc615525a5396ad6ed7","lines":"a line is <source url>#L<line>"},"steps":{"event":"[line, \"event\", name, handled]: raises an event of this object; handled 1 when it has an IsHandled parameter","call":"[line, \"call\", name, arguments]: calls a procedure of this object","ext":"[line, \"ext\", type, id, name, arguments]: calls a procedure of another object, through a variable declared with that type","write":"[line, \"write\", table id, method, 1 when called with true]: Insert, Modify, ModifyAll, Delete, DeleteAll or Rename","validate":"[line, \"validate\", table id, field name]","run":"[line, \"run\", type, id]: Codeunit.Run, Page.Run, Report.Run and their kin"},"objects":{"codeunit:1237":{"name":"Get Json Structure","url":"https://jonas-paprotka.de/ref/codeunit/1237-get-json-structure/"},"codeunit:419":{"name":"File Management","url":"https://jonas-paprotka.de/ref/codeunit/419-file-management/"},"table:1235":{"name":"XML Buffer","url":"https://jonas-paprotka.de/ref/table/1235-xml-buffer/"}},"procs":[{"name":"InitializeXMLBufferFrom","line":25,"kind":"procedure","params":2,"steps":[[28,"call","InitializeXMLReaderSettings",0],[29,"call","CreateXMLReaderFrom",1],[30,"call","ReadXmlReader",0],[31,"call","ParseXML",1]]},{"name":"InitializeXMLBufferFromStream","line":34,"kind":"procedure","params":2,"steps":[[37,"call","InitializeXMLReaderSettings",0],[38,"call","CreateXMLReaderFromInStream",1],[39,"call","ReadXmlReader",0],[40,"call","ParseXML",1]]},{"name":"InitializeXMLBufferFromText","line":43,"kind":"procedure","params":2,"steps":[[45,"call","InitializeXMLReaderSettings",0],[46,"call","CreateXmlReaderFromXmlText",1],[47,"call","ReadXmlReader",0],[48,"call","ParseXML",1]]},{"name":"GenerateStructureFromPath","line":52,"kind":"procedure","params":2,"steps":[[55,"call","InitializeXMLReaderSettings",0],[56,"call","CreateXMLReaderFromPath",1],[57,"call","ReadXmlReader",0],[58,"call","ParseXML",1],[60,"ext","codeunit",1237,"GenerateStructure",2]]},{"name":"GenerateStructure","line":63,"kind":"procedure","params":2,"steps":[[65,"call","InitializeXMLReaderSettings",0],[66,"call","CreateXMLReaderFromOutStream",1],[67,"call","ReadXmlReader",0],[68,"call","ParseXML",1]]},{"name":"CreateXMLReaderFrom","line":71,"kind":"procedure","access":"local","params":1,"steps":[[75,"call","CreateXMLReaderFromPath",1],[77,"call","CreateXMLReaderFromInStream",1],[79,"call","CreateXMLReaderFromOutStream",1]]},{"name":"CreateXMLReaderFromPath","line":85,"kind":"procedure","access":"local","params":1,"steps":[[89,"ext","codeunit",419,"IsAllowedPath",2]]},{"name":"ParseXML","line":119,"kind":"procedure","access":"local","params":1,"steps":[[126,"call","ParseXMLIteratively",2]]},{"name":"ParseXMLIteratively","line":134,"kind":"procedure","access":"local","params":2,"steps":[[143,"call","IsParentElement",1],[145,"call","ParseCurrentXmlNode",6]]},{"name":"ParseCurrentXmlNode","line":149,"kind":"procedure","access":"local","params":6,"steps":[[151,"call","IsParentElement",1],[153,"call","IsChildElement",1],[154,"call","ParseXMLIteratively",2],[157,"call","ReadAndInsertXmlElement",5]]},{"name":"ReadAndInsertXmlElement","line":170,"kind":"procedure","access":"local","params":5,"steps":[[177,"call","ProcessXmlElement",4],[183,"call","AddXmlTextNodeIntoParentXMLBuffer",1],[185,"call","AddXmlTextNodeIntoParentXMLBuffer",1],[189,"call","InsertXmlProcessingInstruction",3],[196,"event","OnAfterReadAndInsertXmlElement",0]]},{"name":"ProcessXmlElement","line":199,"kind":"procedure","access":"local","params":4,"steps":[[203,"call","InsertXmlElement",3],[209,"call","InsertXmlAttribute",3]]},{"name":"InsertXmlElement","line":213,"kind":"procedure","access":"local","params":3,"steps":[[224,"call","InsertElement",6]]},{"name":"InsertXmlAttribute","line":227,"kind":"procedure","access":"local","params":3,"steps":[[237,"call","InsertAttribute",6]]},{"name":"InsertXmlProcessingInstruction","line":240,"kind":"procedure","access":"local","params":3,"steps":[[251,"call","InsertProcessingInstruction",6]]},{"name":"AddXmlTextNodeIntoParentXMLBuffer","line":269,"kind":"procedure","access":"local","params":1,"steps":[[274,"ext","table",1235,"SetValueWithoutModifying",1],[275,"validate",1235,"Data Type"],[275,"call","GetType",1],[276,"write",1235,"Modify"]]},{"name":"InsertAttribute","line":279,"kind":"procedure","params":6,"steps":[[284,"event","OnBeforeInsertAttribute",1],[296,"ext","table",1235,"SetValueWithoutModifying",1],[298,"call","GetType",1],[302,"write",1235,"Insert"]]},{"name":"InsertAttributeWithNamespace","line":305,"kind":"procedure","params":6,"steps":[[312,"event","OnBeforeInsertAttributeWithNamespace",1],[316,"call","SplitXmlElementName",3],[327,"ext","table",1235,"SetValueWithoutModifying",1],[329,"call","GetType",1],[333,"write",1235,"Insert"]]},{"name":"InsertElement","line":336,"kind":"procedure","params":6,"steps":[[343,"event","OnBeforeInsertElement",1],[347,"call","SplitXmlElementName",3],[361,"ext","table",1235,"SetValueWithoutModifying",1],[366,"event","OnInsertElementOnBeforeInsertXMLBuffer",0],[367,"write",1235,"Insert"]]},{"name":"InsertProcessingInstruction","line":370,"kind":"procedure","params":6,"steps":[[381,"ext","table",1235,"SetValueWithoutModifying",1],[385,"write",1235,"Insert"]]}]}