Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add JSON Marshalling support to device and entity #45

Merged
merged 1 commit into from
Nov 11, 2024

Conversation

DerAndereAndi
Copy link
Member

Both DeviceInterface and EntityInterface implementations (e.g. DeviceRemoteInterface and EntityRemoteInterface) are used as arguments in API calls and return values.

When these API calls are used via interprocess communication protocols based on JSON, then the easiest way is to convert them into their addresses to be identified.

This change adds support for this need.

Both DeviceInterface and EntityInterface implementations (e.g. DeviceRemoteInterface and EntityRemoteInterface) are used as arguments in API calls and return values.

When these API calls are used via interprocess communication protocols based on JSON, then the easiest way is to convert them into their addresses to be identified.

This change adds support for this need.
@DerAndereAndi DerAndereAndi added the enhancement New feature or request label Nov 8, 2024
@DerAndereAndi DerAndereAndi marked this pull request as draft November 8, 2024 14:26
@coveralls
Copy link

Coverage Status

coverage: 93.681% (-0.04%) from 93.72%
when pulling 8aa7206 on feature/json-marshal-support
into c2d2b16 on dev.

@sthelen-enqs
Copy link

sthelen-enqs commented Nov 8, 2024

This looks useful, I'll check out if EntityInterface/DeviceInterface would need to mention that they extend json.Marshaler or if that gets picked up automatically next week.

@sthelen-enqs
Copy link

So I've tested, and this does just work without needing to explicitly add json.Marshaler to any of the interfaces.

@DerAndereAndi DerAndereAndi marked this pull request as ready for review November 11, 2024 10:02
@DerAndereAndi
Copy link
Member Author

Thanks for verifying it @sthelen-enqs

@DerAndereAndi DerAndereAndi merged commit fb7dc01 into dev Nov 11, 2024
6 checks passed
@DerAndereAndi DerAndereAndi deleted the feature/json-marshal-support branch November 11, 2024 10:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants