langtools/test/tools/javac/annotations/repeatingAnnotations/DefaultCasePresent.java
equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. |
7 * published by the Free Software Foundation. |
27 * @author sogoel |
27 * @author sogoel |
28 * @summary Default case for methods other than value() in ContainerAnno |
28 * @summary Default case for methods other than value() in ContainerAnno |
29 * @compile DefaultCasePresent.java |
29 * @compile DefaultCasePresent.java |
30 */ |
30 */ |
31 |
31 |
32 import java.lang.annotation.ContainedBy; |
32 import java.lang.annotation.Repeatable; |
33 import java.lang.annotation.ContainerFor; |
|
34 |
33 |
35 @ContainedBy(FooContainer.class) |
34 @Repeatable(FooContainer.class) |
36 @interface Foo {} |
35 @interface Foo {} |
37 |
36 |
38 @ContainerFor(Foo.class) |
|
39 @interface FooContainer { |
37 @interface FooContainer { |
40 Foo[] value(); |
38 Foo[] value(); |
41 String other() default "other-method"; |
39 String other() default "other-method"; |
42 } |
40 } |
43 |
41 |