From 873f9e41b441fb91f2500c0f5759841d8f115062 Mon Sep 17 00:00:00 2001 From: Muthuraj Date: Fri, 15 Jul 2022 01:09:09 +0530 Subject: [PATCH] Create README.md --- README.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..d28c241 --- /dev/null +++ b/README.md @@ -0,0 +1,24 @@ +# moshi-gson-interop-retrofit-converter + +A [Retrofit](https://square.github.io/retrofit/) converter that converts both [Gson](https://github.com/google/gson) and [Moshi](https://github.com/square/moshi) models. + +This tool can be used in the projec where both `Gson` and `Moshi` are present. + +Note that, this won't work if a particular model class is mixed with both Gson and Moshi. +This basically checks the root class of the response type and if it is a Gson model, all of its fields will also be parsed as Gson. And if it is a Moshi model, all of its fields will be parsed as Moshi + +# Installation + +Add to _build.gradle_: +```groovy +allprojects { + repositories { + ... + maven { url 'https://jitpack.io' } + } +} +``` +Add the dependency +```groovy +implementation 'com.github.muthuraj57:moshi-gson-interop-retrofit-converter:1.0.0' +```