15
15
*/
16
16
public class TokenFilter
17
17
{
18
-
19
18
/**
20
19
* Enumeration that controls how TokenFilter return values are interpreted.
21
20
*
@@ -58,9 +57,9 @@ public enum Inclusion {
58
57
protected TokenFilter () { }
59
58
60
59
/*
61
- /**********************************************************
60
+ /**********************************************************************
62
61
/* API, structured values
63
- /**********************************************************
62
+ /**********************************************************************
64
63
*/
65
64
66
65
/**
@@ -134,9 +133,9 @@ public void filterFinishObject() { }
134
133
public void filterFinishArray () { }
135
134
136
135
/*
137
- /**********************************************************
136
+ /**********************************************************************
138
137
/* API, properties/elements
139
- /**********************************************************
138
+ /**********************************************************************
140
139
*/
141
140
142
141
/**
@@ -224,9 +223,9 @@ public TokenFilter includeRootValue(int index) {
224
223
}
225
224
226
225
/*
227
- /**********************************************************
226
+ /**********************************************************************
228
227
/* API, scalar values (being read)
229
- /**********************************************************
228
+ /**********************************************************************
230
229
*/
231
230
232
231
/**
@@ -249,9 +248,9 @@ public boolean includeValue(JsonParser p) throws IOException {
249
248
}
250
249
251
250
/*
252
- /**********************************************************
251
+ /**********************************************************************
253
252
/* API, scalar values (being written)
254
- /**********************************************************
253
+ /**********************************************************************
255
254
*/
256
255
257
256
/**
@@ -432,18 +431,40 @@ public boolean includeEmbeddedValue(Object value) {
432
431
return _includeScalar ();
433
432
}
434
433
434
+ /**
435
+ * Call made to verify whether leaf-level empty Array value
436
+ * should be included in output or not.
437
+ *
438
+ * @param contentsFiltered True if Array had contents but they were
439
+ * filtered out (NOT included); false if we had actual empty Array.
440
+ *
441
+ * @return True if value is to be included; false if not
442
+ *
443
+ * @since 2.14
444
+ */
435
445
public boolean includeEmptyArray (boolean contentsFiltered ) {
436
446
return false ;
437
447
}
438
448
449
+ /**
450
+ * Call made to verify whether leaf-level empty Object value
451
+ * should be included in output or not.
452
+ *
453
+ * @param contentsFiltered True if Object had contents but they were
454
+ * filtered out (NOT included); false if we had actual empty Object.
455
+ *
456
+ * @return True if value is to be included; false if not
457
+ *
458
+ * @since 2.14
459
+ */
439
460
public boolean includeEmptyObject (boolean contentsFiltered ) {
440
461
return false ;
441
462
}
442
463
443
464
/*
444
- /**********************************************************
465
+ /**********************************************************************
445
466
/* Overrides
446
- /**********************************************************
467
+ /**********************************************************************
447
468
*/
448
469
449
470
@ Override
@@ -455,9 +476,9 @@ public String toString() {
455
476
}
456
477
457
478
/*
458
- /**********************************************************
479
+ /**********************************************************************
459
480
/* Other methods
460
- /**********************************************************
481
+ /**********************************************************************
461
482
*/
462
483
463
484
/**
0 commit comments