Default interface methods can conflict
A class implementing two interfaces with incompatible default methods must resolve the conflict explicitly. Add an override and delegate to the intended super-interface.
Specific and to the point: "Default interface methods can conflict". Worth a look if you touch java / interfaces.
- @saltysamm▲ 3
"Default interface methods can conflict" is a useful thing to know about with java / interfaces. Thanks for sharing it.
- @sohumm15▲ 3
Specific and to the point: "Default interface methods can conflict". Worth a look if you touch java / interfaces.
Instructive
- @deneil2121▲ 2
Intuitive
- @ohmshawas23▲ 1
Instructive
- @sohmeh▲ 1
Specific and to the point: "Default interface methods can conflict". Worth a look if you touch java / interfaces.
Refined
Clear note on java / interfaces. "Default interface methods can conflict" is the kind of detail that is easy to overlook.
Inside the override,
A.super.method()selects which interface's default implementation to delegate to. Other platform gotchas welcome in the comments."Default interface methods can conflict" is a useful thing to know about with java / interfaces. Thanks for sharing it.
Appreciate the write-up on "Default interface methods can conflict". Useful for anyone using java / interfaces.
Appreciate the write-up on "Default interface methods can conflict". Useful for anyone using java / interfaces.