Skip to content

Commit 634923f

Browse files
authored
Revert "Merge branch '2.x' into 2.x" (#5373)
This reverts commit 7657bab, reversing changes made to a5844e9.
1 parent 93b0b02 commit 634923f

15 files changed

+13
-732
lines changed

src/main/java/com/fasterxml/jackson/databind/ObjectMapper.java

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1896,24 +1896,6 @@ public ObjectMapper setDefaultPropertyInclusion(JsonInclude.Value incl) {
18961896
return this;
18971897
}
18981898

1899-
/**
1900-
* Method for setting default alternative radix that applies to integral types for serialization
1901-
* and deserialization of such types as strings.
1902-
* This configuration override is applied for all integral properties for which there are no per-type
1903-
* or per-property overrides (via annotations or config overrides).
1904-
*<p>
1905-
* NOTE: in Jackson 3.x all configuration goes through {@code ObjectMapper} builders,
1906-
* see {@link com.fasterxml.jackson.databind.cfg.MapperBuilder},
1907-
* and this method will be removed from 3.0.
1908-
*
1909-
* @since 2.21
1910-
*/
1911-
public ObjectMapper setDefaultFormat(String radix) {
1912-
_configOverrides.setDefaultRadix(radix);
1913-
return this;
1914-
}
1915-
1916-
19171899
/**
19181900
* Short-cut for:
19191901
*<pre>

src/main/java/com/fasterxml/jackson/databind/cfg/BaseSettings.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ public BaseSettings(ClassIntrospector ci, AnnotationIntrospector ai,
184184
_defaultBase64 = defaultBase64;
185185
_typeValidator = ptv;
186186
_accessorNaming = accNaming;
187-
_cacheProvider = cacheProvider;;
187+
_cacheProvider = cacheProvider;
188188
}
189189

190190
/**

src/main/java/com/fasterxml/jackson/databind/cfg/ConfigOverrides.java

Lines changed: 1 addition & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ public class ConfigOverrides
1717
implements java.io.Serializable
1818
{
1919
private static final long serialVersionUID = 1L;
20-
private static final String DEFAULT_RADIX = "10";
2120

2221
/**
2322
* Per-type override definitions
@@ -56,14 +55,6 @@ public class ConfigOverrides
5655
*/
5756
protected Boolean _defaultLeniency;
5857

59-
/**
60-
* Global default radix to apply to an integral type outputted as string. This has the lowest precedence out of all
61-
* other methods of enforcing an alternative radix.
62-
*
63-
* @since 2.21
64-
*/
65-
protected String _defaultRadix;//TODO(Davyd Fridman): Change from string to int once JsonFormat has an actual radix field
66-
6758
/*
6859
/**********************************************************************
6960
/* Life cycle
@@ -76,32 +67,13 @@ public ConfigOverrides() {
7667
JsonInclude.Value.empty(),
7768
JsonSetter.Value.empty(),
7869
VisibilityChecker.Std.defaultInstance(),
79-
null, null, DEFAULT_RADIX
70+
null, null
8071
);
8172
}
8273

83-
/**
84-
* @since 2.21
85-
*/
86-
protected ConfigOverrides(Map<Class<?>, MutableConfigOverride> overrides,
87-
JsonInclude.Value defIncl, JsonSetter.Value defSetter,
88-
VisibilityChecker<?> defVisibility, Boolean defMergeable, Boolean defLeniency,
89-
String defRadix)
90-
{
91-
_overrides = overrides;
92-
_defaultInclusion = defIncl;
93-
_defaultSetterInfo = defSetter;
94-
_visibilityChecker = defVisibility;
95-
_defaultMergeable = defMergeable;
96-
_defaultLeniency = defLeniency;
97-
_defaultRadix = defRadix;
98-
}
99-
10074
/**
10175
* @since 2.10
102-
* @deprecated since 2.21
10376
*/
104-
@Deprecated
10577
protected ConfigOverrides(Map<Class<?>, MutableConfigOverride> overrides,
10678
JsonInclude.Value defIncl, JsonSetter.Value defSetter,
10779
VisibilityChecker<?> defVisibility, Boolean defMergeable, Boolean defLeniency)
@@ -225,13 +197,6 @@ public VisibilityChecker<?> getDefaultVisibility() {
225197
return _visibilityChecker;
226198
}
227199

228-
/**
229-
* @since 2.21
230-
*/
231-
public String getDefaultRadix() {
232-
return _defaultRadix;
233-
}
234-
235200
/**
236201
* @since 2.9
237202
*/
@@ -267,13 +232,6 @@ public void setDefaultVisibility(VisibilityChecker<?> v) {
267232
_visibilityChecker = v;
268233
}
269234

270-
/**
271-
* @since 2.21
272-
*/
273-
public void setDefaultRadix(String v) {
274-
this._defaultRadix = v;
275-
}
276-
277235
/*
278236
/**********************************************************************
279237
/* Helper methods

src/main/java/com/fasterxml/jackson/databind/cfg/MapperBuilder.java

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
import java.util.function.Consumer;
88

99
import com.fasterxml.jackson.annotation.JsonAutoDetect;
10-
import com.fasterxml.jackson.annotation.JsonFormat;
1110
import com.fasterxml.jackson.annotation.JsonInclude;
1211
import com.fasterxml.jackson.annotation.JsonSetter;
1312
import com.fasterxml.jackson.annotation.JsonTypeInfo;
@@ -748,20 +747,6 @@ public B defaultPropertyInclusion(JsonInclude.Value incl) {
748747
return _this();
749748
}
750749

751-
/**
752-
* Method for configured default radix to use for serialization/deserialization of integral types as strings.
753-
*
754-
* @param radix Default radix to use on integral properties
755-
*
756-
* @return This builder instance to allow call chaining
757-
*
758-
* @since 2.11
759-
*/
760-
public B defaultFormat(String radix) {
761-
_mapper.setDefaultFormat(radix);
762-
return _this();
763-
}
764-
765750
/*
766751
/**********************************************************************
767752
/* Configuring Mix-ins

src/main/java/com/fasterxml/jackson/databind/cfg/MapperConfig.java

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -507,14 +507,6 @@ public JsonInclude.Value getDefaultInclusion(Class<?> baseType,
507507
return result;
508508
}
509509

510-
/**
511-
* Accessor for default radix to apply to integral types when serializing them as string.
512-
* The radix obtained from this accessor should have the lowest precedence.
513-
*
514-
* @since 2.21
515-
*/
516-
public abstract String getDefaultRadix();
517-
518510
/**
519511
* Accessor for default format settings to use for serialization (and, to a degree
520512
* deserialization), considering baseline settings and per-type defaults

src/main/java/com/fasterxml/jackson/databind/cfg/MapperConfigBase.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -777,11 +777,6 @@ public final JsonInclude.Value getDefaultInclusion(Class<?> baseType,
777777
return def.withOverrides(v);
778778
}
779779

780-
@Override
781-
public String getDefaultRadix() {
782-
return _configOverrides.getDefaultRadix();
783-
}
784-
785780
@Override
786781
public final JsonFormat.Value getDefaultPropertyFormat(Class<?> type) {
787782
return _configOverrides.findFormatDefaults(type);

src/main/java/com/fasterxml/jackson/databind/deser/std/FromStringWithRadixToNumberDeserializer.java

Lines changed: 0 additions & 52 deletions
This file was deleted.

0 commit comments

Comments
 (0)