|
1 | 1 | New parameter added to the write function that allows you to customize the xml declaration, which was previously hard-coded. |
2 | 2 |
|
3 | | -The standard functionality is retained; if you don't specify the xml_declaration_definition parameter, the previous standard declaration is used. "<?xml version='1.0' encoding='{encoding}'?> |
| 3 | +The standard functionality is retained; if you don't specify the xml_declaration_definition parameter, the previous standard declaration is used. ``<?xml version='1.0' encoding='{encoding}'?>`` |
4 | 4 |
|
5 | 5 | When specifying the parameter, the following options are available. |
6 | 6 | E.g.: |
7 | | -- tee.write(file, encoding="utf-8", xml_declaration=True, xml_declaration_definition='''<?xml version="{version}" encoding="{encoding}"?>''') |
8 | 7 |
|
9 | | -- tee.write(file, encoding="utf-8", xml_declaration=True, xml_declaration_definition='''<?xml version="1.1" encoding="{encoding}"?>''') |
| 8 | +- tree.write(file, encoding="utf-8", xml_declaration=True, xml_declaration_definition='''<?xml version="{version}" encoding="{encoding}"?>''') |
| 9 | +- tree.write(file, encoding="utf-8", xml_declaration=True, xml_declaration_definition='''<?xml version="1.1" encoding="{encoding}"?>''') |
| 10 | +- tree.write(file, encoding="utf-8", xml_declaration=True, xml_declaration_definition='''<?xml version="1.1"?>''') |
10 | 11 |
|
11 | | -- tee.write(file, encoding="utf-8", xml_declaration=True, xml_declaration_definition='''<?xml version="1.1"?>''') |
12 | | - |
13 | | -The placeholders {version} and {encoding} are replaced, version is always 1.0 and enconding depends on the code as before. |
| 12 | +The placeholders {version} and {encoding} are replaced, version is always 1.0 and enconding depends on the code as before. |
0 commit comments