|
9 | 9 | * It serves as a default or fallback strategy when no specific field filtering logic is required.
|
10 | 10 | */
|
11 | 11 | public class BasicFiledFilter implements FieldFilter {
|
12 |
| - /** |
13 |
| - * A singleton instance of {@code BasicFieldFilter}. |
14 |
| - * Since the filter does not maintain any state and allows all operations, it can be reused across the application. |
15 |
| - */ |
| 12 | + /** |
| 13 | + * default constructor |
| 14 | + */ |
| 15 | + public BasicFiledFilter() { |
| 16 | + super(); |
| 17 | + } |
| 18 | + |
| 19 | + /** |
| 20 | + * A singleton instance of {@code BasicFieldFilter}. |
| 21 | + * Since the filter does not maintain any state and allows all operations, it can be reused across the application. |
| 22 | + */ |
16 | 23 | public final static BasicFiledFilter SINGLETON = new BasicFiledFilter();
|
17 | 24 |
|
18 | 25 | /**
|
19 |
| - * Always allows using the specified field. |
20 |
| - * |
21 |
| - * @param field The field to check. |
22 |
| - * @return Always returns {@code true}. |
23 |
| - */ |
| 26 | + * Always allows using the specified field. |
| 27 | + * |
| 28 | + * @param field The field to check. |
| 29 | + * @return Always returns {@code true}. |
| 30 | + */ |
24 | 31 | @Override
|
25 | 32 | public boolean canUse(Field field) {
|
26 | 33 | return true;
|
27 | 34 | }
|
28 | 35 |
|
29 | 36 | /**
|
30 |
| - * Always allows using the specified field in conjunction with a method. |
31 |
| - * |
32 |
| - * @param field The field to check. |
33 |
| - * @param method The method to check. This parameter is not used in the current implementation. |
34 |
| - * @return Always returns {@code true}. |
35 |
| - */ |
| 37 | + * Always allows using the specified field in conjunction with a method. |
| 38 | + * |
| 39 | + * @param field The field to check. |
| 40 | + * @param method The method to check. This parameter is not used in the current implementation. |
| 41 | + * @return Always returns {@code true}. |
| 42 | + */ |
36 | 43 | @Override
|
37 | 44 | public boolean canUse(Field field, Method method) {
|
38 | 45 | return true;
|
39 | 46 | }
|
40 | 47 |
|
41 | 48 | /**
|
42 |
| - * Always allows reading the specified field. |
43 |
| - * |
44 |
| - * @param field The field to check. |
45 |
| - * @return Always returns {@code true}. |
46 |
| - */ |
| 49 | + * Always allows reading the specified field. |
| 50 | + * |
| 51 | + * @param field The field to check. |
| 52 | + * @return Always returns {@code true}. |
| 53 | + */ |
47 | 54 | @Override
|
48 | 55 | public boolean canRead(Field field) {
|
49 | 56 | return true;
|
50 | 57 | }
|
51 | 58 |
|
52 | 59 | /**
|
53 |
| - * Always allows writing to the specified field. |
54 |
| - * |
55 |
| - * @param field The field to check. |
56 |
| - * @return Always returns {@code true}. |
57 |
| - */ |
| 60 | + * Always allows writing to the specified field. |
| 61 | + * |
| 62 | + * @param field The field to check. |
| 63 | + * @return Always returns {@code true}. |
| 64 | + */ |
58 | 65 | @Override
|
59 | 66 | public boolean canWrite(Field field) {
|
60 | 67 | return true;
|
|
0 commit comments