Import tr181-2.18 xml

This commit is contained in:
Vivek Kumar Dutta 2024-07-25 11:17:17 +05:30
parent 93a6f6f51c
commit 85318dac63
6 changed files with 16897 additions and 8724 deletions

View file

@ -40,7 +40,7 @@ echo "Check if the required tools are generated"
[ ! -f "out/datamodel_default.xml" ] && echo "XML file with BBF format doesn't exist" && exit 1
echo "Validate datamodel_default generated XML file"
xmllint --schema test/tools/cwmp-datamodel-1-8.xsd out/datamodel_default.xml --noout
xmllint --schema test/tools/cwmp-datamodel-*.xsd out/datamodel_default.xml --noout
check_ret $?
echo "Generation of xml and xls artifacts :: PASS"

File diff suppressed because it is too large Load diff

View file

@ -3,24 +3,24 @@
Data Model Definition Schema (DM Schema) v1.8
Copyright (c) 2008-2020, Broadband Forum
Redistribution and use in source and binary forms, with or
without modification, are permitted provided that the following
conditions are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following
disclaimer in the documentation and/or other materials
provided with the distribution.
3. Neither the name of the copyright holder nor the names of its
contributors may be used to endorse or promote products
derived from this software without specific prior written
permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND
CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
@ -34,14 +34,14 @@
STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
The above license is used as a license under copyright only.
Please reference the Forum IPR Policy for patent licensing terms
<https://www.broadband-forum.org/ipr-policy>.
Any moral rights which are necessary to exercise under the above
license grant are also deemed granted under this license.
Summary:
CWMP and USP Data Model Definition Schema (DM Schema). DM Instances define CWMP
or USP data models. Within the schema, elements are grouped by category (simple
@ -63,8 +63,8 @@
- updated all of the unique object-name constraints so that the
object/@base attribute is also considered.
- added "prefix" option to the description/@action attribute
- made import/@file attribute required for import element
- removed size facet's default maxLength on string/base64/hexBinary
- made import/@file attribute required for import element
- removed size facet's default maxLength on string/base64/hexBinary
parameters
- added syntax/@command attribute to the syntax element
* cwmp-datamodel-1-4.xsd: July 2011: corresponds to TR-106 Amendment 6
@ -83,7 +83,7 @@
* cwmp-datamodel-1-7.xsd: September 13 2019: September 13 2019:
- supported implementation defaults, version attribute, description templates,
writeOnceReadOnly access type and the decimal datatype
* cwmp-datamodel-1-8.xsd: November 5 2020: November 5 2020: corresponds to TR-106 Amendment 10
* cwmp-datamodel-1-8.xsd: TBD 2020: TBD 2020: corresponds to TR-106 Amendment 9
- allowed command attributes, e.g. mandatory, in component definitions
-->
@ -705,7 +705,7 @@ The range facet MUST NOT be specified for non-numeric data types, i.e. data type
<xs:element name="enumeration" type="tns:EnumerationFacet">
<xs:annotation>
<xs:documentation>Enumeration facets, taken together, define the valid values, e.g. "a" and "b" mean that the value has to be a or b.
The enumeration facet MUST NOT be specified for data types that are not derived from string.
The enumeration facet MUST NOT be specified for data types that are not derived from string.
Derived types MAY add additional enumeration values. See A.2.5.</xs:documentation>
</xs:annotation>
</xs:element>
@ -718,7 +718,7 @@ The enumerationRef facet MUST NOT be specified for data types that are not deriv
<xs:element name="pattern" type="tns:PatternFacet">
<xs:annotation>
<xs:documentation>Pattern attributes, taken together, define valid patterns, e.g. "" and "[0-9A-Fa-f]{6}" means that the value has to be empty or a 6 digit hex string.
The pattern facet MUST NOT be specified for data types that are not derived from string.
The pattern facet MUST NOT be specified for data types that are not derived from string.
Pattern syntax is the same as for XML Schema regular expressions. See https://www.w3.org/TR/xmlschema-2/#regexs.</xs:documentation>
</xs:annotation>
</xs:element>
@ -1192,7 +1192,7 @@ Specify "prefix" to prefix to the previous description, "append" to append to th
</xs:complexType>
<xs:complexType name="DescriptionTemplate">
<xs:annotation>
<xs:documentation>DescriptionTemplate: free text with a length up to 256 characters, which can be added in multiple descriptions and MAY contain a limited amount of mediawiki-like markup as
<xs:documentation>DescriptionTemplate: free text with a length up to 256 characters, which can be added in multiple descriptions and MAY contain a limited amount of mediawiki-like markup as
specified in A.2.2 (same restrictions as tns:Description type</xs:documentation>
</xs:annotation>
<xs:simpleContent>

View file

@ -144,12 +144,13 @@ def generate_bbf_xml_file(output_file, dm_json_files=None):
root.set("xmlns:dm", "urn:broadband-forum-org:cwmp:datamodel-1-8")
root.set("xmlns:dmr", "urn:broadband-forum-org:cwmp:datamodel-report-0-1")
root.set("xmlns:xsi", "http://www.w3.org/2001/XMLSchema-instance")
root.set("xsi:schemaLocation", "urn:broadband-forum-org:cwmp:datamodel-1-8 https://www.broadband-forum.org/cwmp/cwmp-datamodel-1-8.xsd urn:broadband-forum-org:cwmp:datamodel-report-0-1 https://www.broadband-forum.org/cwmp/cwmp-datamodel-report.xsd")
root.set("spec", "urn:broadband-forum-org:tr-181-2-14-1-cwmp")
root.set("file", "tr-181-2-17-0-cwmp-full.xml")
root.set("xsi:schemaLocation", "urn:broadband-forum-org:cwmp:datamodel-1-14 https://www.broadband-forum.org/cwmp/cwmp-datamodel-1-14.xsd urn:broadband-forum-org:cwmp:datamodel-report-1-0 https://www.broadband-forum.org/cwmp/cwmp-datamodel-report-1-0.xsd")
root.set("spec", "urn:broadband-forum-org:tr-181-2-18-0-cwmp")
root.set("file", "tr-181-2-18-0-cwmp.xml")
model = ET.SubElement(root, "model")
model.set("name", "Device:2.17")
model.set("name", "Device:2.18")
for entry in LIST_SUPPORTED_DM:
name = entry.get("param")