File tree Expand file tree Collapse file tree
src/main/java/org/bbottema/javareflection/model Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11package org .bbottema .javareflection .model ;
22
3+ import edu .umd .cs .findbugs .annotations .SuppressFBWarnings ;
4+ import lombok .Value ;
35import org .jetbrains .annotations .NotNull ;
46import org .jetbrains .annotations .Nullable ;
57
911/**
1012 * A wrapper class that keeps a property ({@link Field}) and its setter/getter method(s) in one place.
1113 */
14+ @ Value
15+ @ SuppressFBWarnings (justification = "Generated code" )
1216public class FieldWrapper {
1317
1418 @ NotNull
@@ -17,41 +21,4 @@ public class FieldWrapper {
1721 private final Method getter ;
1822 @ Nullable
1923 private final Method setter ;
20-
21- /**
22- * Initializes the wrapper with field, getter and setter, all optional.
23- *
24- * @param field A {@link Field}.
25- * @param getter A getter {@link Method} for the field.
26- * @param setter A setter {@link Method} for the field.
27- */
28- public FieldWrapper (@ NotNull Field field , @ Nullable Method getter , @ Nullable Method setter ) {
29- this .field = field ;
30- this .getter = getter ;
31- this .setter = setter ;
32- }
33-
34- /**
35- * @return {@link #field}.
36- */
37- @ NotNull
38- public Field getField () {
39- return field ;
40- }
41-
42- /**
43- * @return {@link #getter}.
44- */
45- @ Nullable
46- public Method getGetter () {
47- return getter ;
48- }
49-
50- /**
51- * @return {@link #setter}.
52- */
53- @ Nullable
54- public Method getSetter () {
55- return setter ;
56- }
5724}
You can’t perform that action at this time.
0 commit comments