All Versions
9
Latest Version
Avg Release Cycle
43 days
Latest Release
2444 days ago
Changelog History
Changelog History
-
v2.5.0 Changes
January 17, 2017typeToken
removes generic type parameter wildcards. This means thattypeToken<List<Something>>
will now returnList<Something>
instead ofList<? extends Something>
.- Added the
byNullable*
functions to delegate to nullable values inside aJsonObject
orJsonArray
(thanks to @eygraber Eliezer Graber). - Added the possibility to define a default value to the delegate
by*
methods (thanks to @eygraber Eliezer Graber). - Added the
addProperty
andaddPropertyIfNotNull
methods toJsonObject
(thanks to @ColinHebert Colin Hebert). - Added the ability to add a
JsonSerializer
andJsonDeserializer
withregisterTypeAdapter
(thanks to @ColinHebert Colin Hebert). - Gson
2.8.0
, see changelog. - Kotlin
1.0.6
- Gradle
3.3
-
v2.4.0 Changes
August 10, 2016typeToken
is more permissive with generic parameters. It tries to infer generic wildcards.- Kotlin
1.0.3
- Gradle
2.14.1
. - Spek
1.0.25
.
-
v2.3.0 Changes
June 22, 2016- In a
JsonSerializer
, usingit.context.serialize
now serializes according to the object real type (at runtime), which is consistent withGson.toJson
. Serializing according to the compile time type is possible withit.context.typedSerialize
, which is consistent withGson.typedToJson
. - Gson
2.7
, see changelog. - Kotlin
1.0.2-1
- In a
-
v2.2.2 Changes
June 13, 2016jsonArray
andjsonObject
functions are now usable withIterable
andSequence
.- Gradle
2.13
.
-
v2.2.1 Changes
May 23, 2016- Kotlin
1.0.2
. - Spek
1.0.9
.
- Kotlin
-
v2.2.0 Changes
March 30, 2016- Kotlin
1.0.1
. - Gson
2.6.2
. - Spek
1.0.0
. - Added
read
andwrite
toregisterTypeAdapter
andregisterTypeHierarchyAdapter
. - Added
registerNullableTypeAdapter
abdregisterNullableTypeHierarchyAdapter
. - Renamed
typeToken
togsonTypeToken
andregistrationTypeToken
totypeToken
. That means thattypeToken<List<*>>
will now return aClass
. If still want aParametrizedType
corresponding to java'sList<? extends Object>
, you should usegsonTypeToken
.
- Kotlin
-
v2.1.0 Changes
February 16, 2016- Kotlin
1.0.0
. - gson
2.6.1
.
- Kotlin
-
v2.0.1 Changes
February 08, 2016- Correcting #11:
typeToken
is back to its classic gson semantic. registrationTypeToken
has the semantic of the previoustypeToken
.
- Correcting #11:
-
v2.0.0 Changes
February 05, 2016- Kotlin
1.0.0-beta-1036
. - Gson
2.5
. - Introducing
typedToJson
. typeToken
now returns aClass
instead of aParameterizedType
when for non specialized generic types (such asList<*>*
).- New syntax for
registerTypeAdapter
andregisterTypeHierarchyAdapter
for declaring type adapters (serializers and deserializers).
- Kotlin