Define an abstract class that inherits an infterface, but does not implement it

前端 未结 2 381
执念已碎
执念已碎 2021-01-12 12:29

incorporating leppies feedback it compiles - but IMO some drawbacks I want each sub class to be forced by the compiler to define their own Uri property. Code as it is now:

2条回答
  •  太阳男子
    2021-01-12 13:10

    From a .NET point of view, you would need to at least provide an abstract implementation for the interface. But that again could proof problematic due to default interface accessibility, which would require some more glue again for an explicit implementation.

提交回复
热议问题