Java - Method name collision in interface implementation

前端 未结 7 1363
渐次进展
渐次进展 2020-11-22 13:23

If I have two interfaces , both quite different in their purposes , but with same method signature , how do I make a class implement both without being forced to write a sin

相关标签:
7条回答
  • 2020-11-22 14:02

    You can use an Adapter pattern in order to make these work. Create two adapter for each interface and use that. It should solve the problem.

    0 讨论(0)
提交回复
热议问题