-7

I just find that interface Path has extended 3 class, which against the principle;

public interface Path
extends Comparable<Path>, Iterable<Path>, Watchable

????

Japhy Fan
  • 45
  • 3
  • 8

1 Answers1

0

The extends keyword is used with interfaces to make them extend other interfaces (that is not extending multiple classes).

All the types after the extends keyword of Path are interfaces (Comparable, Iterable, and Watchable).

ernest_k
  • 44,416
  • 5
  • 53
  • 99