-
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.
Add support for octet-string-typed config variables in YAML. (#21699)
- Loading branch information
1 parent
5d5b69e
commit aec3d1d
Showing
8 changed files
with
24 additions
and
22 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
5 changes: 5 additions & 0 deletions
5
examples/chip-tool/templates/tests/partials/octet_string_value.zapt
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,5 @@ | ||
{{#if (isHexString value)}} | ||
chip::ByteSpan(chip::Uint8::from_const_char("{{octetStringFromHexString value}}{{extraGarbage}}"), {{octetStringLengthFromHexString value}}) | ||
{{else}} | ||
chip::ByteSpan(chip::Uint8::from_const_char("{{octetStringEscapedForCLiteral value}}{{extraGarbage}}"), {{value.length}}) | ||
{{/if}} |
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
5 changes: 5 additions & 0 deletions
5
examples/darwin-framework-tool/templates/tests/partials/octet_string_value.zapt
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,5 @@ | ||
{{~#if (isHexString value)}} | ||
[[NSData alloc] initWithBytes:"{{octetStringFromHexString value}}" length:{{octetStringLengthFromHexString value}}] | ||
{{else}} | ||
[[NSData alloc] initWithBytes:"{{octetStringEscapedForCLiteral value}}" length:{{value.length}}] | ||
{{/if}} |
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