blob: 4682862710e6a411e4d7736d6626f00c5dc7c5ea (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
// version 15:
public class Sealed {
public abstract sealed class Parent permits Child1, Child2 {
}
public final class Child1 extends Parent {
}
public abstract non-sealed class Child2 extends Parent {
}
public sealed interface SealedInterface permits ChildInterface1 {
}
public non-sealed interface ChildInterface1 extends SealedInterface {
}
}
|