-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Android] Fix generated struct variable type (#29360)
* Fix generated struct variable type * generated files.gni * Update Struct Class for avoiding build error * Update unit test * update kotlin codestyle * Add jinja test file * Update script test code
- Loading branch information
1 parent
08f42c0
commit 3dfc703
Showing
155 changed files
with
1,416 additions
and
1,981 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
scripts/py_matter_idl/matter_idl/generators/java/ChipStructFiles_gni.jinja
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import("//build_overrides/build.gni") | ||
import("//build_overrides/chip.gni") | ||
|
||
structs_sources = [ | ||
{%- for cluster in clientClusters | sort(attribute='name') %} | ||
{%- set typeLookup = idl | createLookupContext(cluster) %} | ||
{%- for struct in cluster.structs | sort(attribute='name') %} | ||
{%- if not struct.tag %} | ||
"${chip_root}/src/controller/java/generated/java/chip/devicecontroller/cluster/structs/{{cluster.name}}Cluster{{struct.name}}.kt", | ||
{%- endif %} | ||
{%- endfor %} | ||
{%- endfor %} | ||
] | ||
|
||
eventstructs_sources = [ | ||
{%- for cluster in clientClusters | sort(attribute='name') %} | ||
{%- set typeLookup = idl | createLookupContext(cluster) %} | ||
{%- for event in cluster.events | sort(attribute='name') %} | ||
{%- if event.fields %} | ||
"${chip_root}/src/controller/java/generated/java/chip/devicecontroller/cluster/eventstructs/{{cluster.name}}Cluster{{event.name}}Event.kt", | ||
{%- endif %} | ||
{%- endfor %} | ||
{%- endfor %} | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 9 additions & 0 deletions
9
scripts/py_matter_idl/matter_idl/tests/outputs/several_clusters/java/files.gni
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import("//build_overrides/build.gni") | ||
import("//build_overrides/chip.gni") | ||
|
||
structs_sources = [ | ||
"${chip_root}/src/controller/java/generated/java/chip/devicecontroller/cluster/structs/SecondClusterFabricDescriptorStruct.kt", | ||
] | ||
|
||
eventstructs_sources = [ | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.