You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@avro.apache.org by GitBox <gi...@apache.org> on 2022/12/06 19:03:25 UTC

[GitHub] [avro] KalleOlaviNiemitalo commented on pull request #1940: AVRO-3603: .NET Reflect Reader and Writer - add interfaces

KalleOlaviNiemitalo commented on PR #1940:
URL: https://github.com/apache/avro/pull/1940#issuecomment-1339838586

   (Setting up a new computer took more time than expected.)
   
   This pull request makes existing classes implement new interfaces, and then uses those interfaces instead of the classes:
   
   - public class ClassCache : public interface ICacheService, public interface IArrayService
   - public class DotnetClass : public interface IDotnetClass
   - internal class DotnetProperty : public interface IDotnetProperty
   
   I worry that these changes will make it more difficult to avoid breaking changes in the future if members are added. Currently, it is possible to add new virtual methods to ClassCache and DotnetClass and provide default implementations. Doing the same in the interfaces would require either using default interface methods, which .NET Framework does not support, or adding more interfaces (e.g. ICacheService2) and checking at run time whether the object implements those.
   
   Does IDotnetProperty need to be public? It is not implemented by any public type, nor used as a parameter or return value of any public method.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@avro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org