Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add a parser for CSA XML data models (project-chip#29888)
* Move xml to say zapxml since that is the format * Start defining a data_model_xml parser (no functionality for now) * Start adding some basic support for data model xml parsing * make the DM parser executable * Start having the ability to parse clusters * More updates, we seem to have parsing for features * Hard-code global attributes * Remove some comments * Add enumeration handling * Add bitmap handling * Restyle * Parse structs * Re-organize parsing a bit * Make a linter happy * Another linter fix * Handling of events * More handling and logic on events * Add support for access privilege parsing * XMLs have maybe invalid enum entries. Handle them gracefully * More attribute handling updates * restyle * Support deprecate constraint * Support constraint decoding, apply on attributes for now * Restyle * Restyle * Field handling * Field handling * Some bug fixing * Start adding command handling * Restyle * Name normalization and more parsing updates * Name normalization and more parsing updates * Better messaging and fix constraint types * Restyle * Start creating a IDL codegen so we can self-test parsed output * Start with listing clusters * Enum listing * A lot more things supported * Attribute rendering * Support for string and octet string sizes * Timed command support * Restyle * Add descriptions to clusters * Attempt to fix up alignment of things * Alignment looks slightly better * Better command separation * Align comments * Align and output descriptions including clusters * More work regarding loop structures * Apply hex formatting to bitmaps. output now seems identical except one whitespace change * Identical output for now * Support API maturity. Notice that doccomments are lost on maturity :( * Fix doxygen parsing for api maturity at the cluster level * Restyle * Support endpoints, although that is not 1:1 as hex encoding and ordering for events is lost * Restyle * Add todo note that default value does not string escaping * Default rendering and add to files * More updates on file dependencies * Unit test IDL generator * Add the IDL unit test as a standard unit test * Update for python compatibility * Fix unit testing of builds when GSDK root is defined * Added a readme file * Restyle * Make xml parser use the idl codegen * Restyle * look to fix misspell warnings * Undo repo update * Fix linter errors * Codegen as idl for data_model_xml_parser.py * Parsing closer to matter idl content * more normalization and type processing * More mandatory conformance logic * Fix mandatory conditionals * Make unit test pass * Fix tests a bit more and make parsers better * Restyle * Ignore min/max values while parsing xmls, even though raw data internally contains them * Restyle * Fix space after click annotations * Compare support for human reviews * Restyle * Fix slash * Undo submodule change * fix xml to zapxml naming changes * Restyle * Update dates from 2022 to 2023 * Add note about the complex test input * Remove unused imports * Restyle * Add some commends based on code review * Add heuristic for setting enum and bitmap sizes, to make output from XML much more readable * Add support for timed and fabric scoped commands * Add missing import --------- Co-authored-by: Andrei Litvin <andreilitvin@google.com>
- Loading branch information