blob: b6765fb20c4355d3c19c577870a310d0ddfd8ac3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
import lombok.experimental.FieldNameConstants;
import lombok.AccessLevel;
@FieldNameConstants(asEnum = true, innerTypeName = "TypeTest")
class FieldNameConstantsHandrolled1 {
int field1, alsoAField, thirdField;
public enum TypeTest {
field1
}
}
@FieldNameConstants(asEnum = true, innerTypeName = "TypeTest")
class FieldNameConstantsHandrolled2 {
int field1, alsoAField, thirdField;
public enum TypeTest {
field1;
public String foo() {
return name();
}
}
}
@FieldNameConstants
class FieldNameConstantsHandrolled3 {
int field1, alsoAField, thirdField;
static class Fields {
public static final int alsoAField = 5;
}
}
|