affederaffe / Tmds.DBus.SourceGenerator

A roslyn source generator for creating proxies targeting the Tmds.DBus.Protocol API
MIT License
7 stars 5 forks source link

[Proposal] Inline `BackingProperties` #10

Closed ShortDevelopment closed 5 months ago

ShortDevelopment commented 6 months ago

Proposal

It would be nice to set properties on an object directly instead of using the BackingProperties property as a proxy. To prevent conflicts, you could implement IMethodHandler explicitly. This would have the added "benefit" of hiding the implementation detail of IMethodHandler.

Implications

Major breaking changes.

affederaffe commented 5 months ago

That's a nice QoL feature, coming soon :tm: The upstream Tmds.DBus.Protocol released with an "official" way of dealing with Variants, so the next version will have the current one replaced, no worries about breaking chances since there will be enough of them anyway. Zero versioning has its advantages.

affederaffe commented 5 months ago

Implemented with https://github.com/affederaffe/Tmds.DBus.SourceGenerator/commit/8d6ae47a7dd3a165265805547e2382d892910137. Note that the CI currently fails because Tmds.DBus.Protocol 16.1 hasn't been published yet on NuGet.

affederaffe commented 5 months ago

Completed with the release of 0.016 on NuGet, see https://www.nuget.org/packages/Tmds.DBus.SourceGenerator/0.0.16.