/** * Helper method that will try to combine values from two {@link Value} * instances, using one as base settings, and the other as overrides * to use instead of base values when defined; base values are only * use if override does not specify a value (matching value is null * or logically missing). * Note that one or both of value instances may be `null`, directly; * if both are `null`, result will also be `null`; otherwise never null. */ public static Value merge(Value base, Value overrides) { return (base == null) ? overrides : base.withOverrides(overrides); }
/** * @since 2.8 */ public static Value mergeAll(Value... values) { Value result = null; for (Value curr : values) { if (curr != null) { result = (result == null) ? curr : result.withOverrides(curr); } } return result; }
@Override public JsonIgnoreProperties.Value findPropertyIgnorals(Annotated a) { JsonIgnoreProperties.Value v2 = _secondary.findPropertyIgnorals(a); JsonIgnoreProperties.Value v1 = _primary.findPropertyIgnorals(a); if (v2 == null) { // shouldn't occur but return v1; } return v2.withOverrides(v1); }
@Override public JsonIgnoreProperties.Value findPropertyIgnorals(Annotated a) { JsonIgnoreProperties.Value v2 = _secondary.findPropertyIgnorals(a); JsonIgnoreProperties.Value v1 = _primary.findPropertyIgnorals(a); return (v2 == null) // shouldn't occur but ? v1 : v2.withOverrides(v1); }
/** * Helper method that will try to combine values from two {@link Value} * instances, using one as base settings, and the other as overrides * to use instead of base values when defined; base values are only * use if override does not specify a value (matching value is null * or logically missing). * Note that one or both of value instances may be `null`, directly; * if both are `null`, result will also be `null`; otherwise never null. */ public static Value merge(Value base, Value overrides) { return (base == null) ? overrides : base.withOverrides(overrides); }
public static Value mergeAll(Value... values) { Value result = null; for (Value curr : values) { if (curr != null) { result = (result == null) ? curr : result.withOverrides(curr); } } return result; }
/** * Helper method that will try to combine values from two {@link Value} * instances, using one as base settings, and the other as overrides * to use instead of base values when defined; base values are only * use if override does not specify a value (matching value is null * or logically missing). * Note that one or both of value instances may be `null`, directly; * if both are `null`, result will also be `null`; otherwise never null. */ public static Value merge(Value base, Value overrides) { return (base == null) ? overrides : base.withOverrides(overrides); }
/** * @since 2.8 */ public static Value mergeAll(Value... values) { Value result = null; for (Value curr : values) { if (curr != null) { result = (result == null) ? curr : result.withOverrides(curr); } } return result; }
/** * Helper method that will try to combine values from two {@link Value} * instances, using one as base settings, and the other as overrides * to use instead of base values when defined; base values are only * use if override does not specify a value (matching value is null * or logically missing). * Note that one or both of value instances may be `null`, directly; * if both are `null`, result will also be `null`; otherwise never null. */ public static Value merge(Value base, Value overrides) { return (base == null) ? overrides : base.withOverrides(overrides); }
/** * @since 2.8 */ public static Value mergeAll(Value... values) { Value result = null; for (Value curr : values) { if (curr != null) { result = (result == null) ? curr : result.withOverrides(curr); } } return result; }
@Override public JsonIgnoreProperties.Value findPropertyIgnorals(Annotated a) { JsonIgnoreProperties.Value v2 = _secondary.findPropertyIgnorals(a); JsonIgnoreProperties.Value v1 = _primary.findPropertyIgnorals(a); return (v2 == null) // shouldn't occur but ? v1 : v2.withOverrides(v1); }