diff --git a/core/src/main/java/io/github/mmm/marshall/spi/AbstractStructuredStringReader.java b/core/src/main/java/io/github/mmm/marshall/spi/AbstractStructuredStringReader.java index bdfd377..d5fca01 100644 --- a/core/src/main/java/io/github/mmm/marshall/spi/AbstractStructuredStringReader.java +++ b/core/src/main/java/io/github/mmm/marshall/spi/AbstractStructuredStringReader.java @@ -40,7 +40,7 @@ protected N readValueAsNumber(NumberType type) { return null; } try { - return type.valueOf(value); + return type.parse(value); } catch (RuntimeException e) { throw error(value, type.getType(), e); } diff --git a/core/src/main/java/io/github/mmm/marshall/spi/AbstractStructuredValueReader.java b/core/src/main/java/io/github/mmm/marshall/spi/AbstractStructuredValueReader.java index 36badc8..ef22c5f 100644 --- a/core/src/main/java/io/github/mmm/marshall/spi/AbstractStructuredValueReader.java +++ b/core/src/main/java/io/github/mmm/marshall/spi/AbstractStructuredValueReader.java @@ -43,7 +43,7 @@ protected N readValueAsNumber(NumberType numberType) { } } else if (value instanceof String) { try { - return numberType.valueOf(value.toString()); + return numberType.parse(value.toString()); } catch (RuntimeException e) { throw error(value, numberType.getType(), e); } diff --git a/impl/jsonp/src/main/java/io/github/mmm/marshall/jsonp/impl/JsonpReader.java b/impl/jsonp/src/main/java/io/github/mmm/marshall/jsonp/impl/JsonpReader.java index 2f8b026..bc75ca4 100644 --- a/impl/jsonp/src/main/java/io/github/mmm/marshall/jsonp/impl/JsonpReader.java +++ b/impl/jsonp/src/main/java/io/github/mmm/marshall/jsonp/impl/JsonpReader.java @@ -148,7 +148,7 @@ protected N readValueAsNumber(NumberType type) { } else if (type == NumberType.LONG) { result = (N) Long.valueOf(this.json.getLong()); } else { - result = type.valueOf(this.json.getString()); + result = type.parse(this.json.getString()); } next(); return result; diff --git a/impl/protobuf/src/main/java/io/github/mmm/marshall/protobuf/impl/ProtoBufReader.java b/impl/protobuf/src/main/java/io/github/mmm/marshall/protobuf/impl/ProtoBufReader.java index a8f3159..a3d35bd 100644 --- a/impl/protobuf/src/main/java/io/github/mmm/marshall/protobuf/impl/ProtoBufReader.java +++ b/impl/protobuf/src/main/java/io/github/mmm/marshall/protobuf/impl/ProtoBufReader.java @@ -402,7 +402,7 @@ protected N readValueAsNumber(NumberType numberType) { return null; } try { - return numberType.valueOf(value); + return numberType.parse(value); } catch (RuntimeException e) { throw error(value, numberType.getType(), e); }