-
public final class MoshiQueryConverterFactory extends Converter.FactoryA Retrofit Converter.Factory that JSON-serializes complex objects used as
@Queryparameters.Retrofit's default behavior for
@Queryis to calltoString()on the value, which produces a Kotlin data class string representation instead of JSON. This factory intercepts non-primitive types and serializes them to JSON via Moshi.
-
-
Constructor Summary
Constructors Constructor Description MoshiQueryConverterFactory(Moshi moshi)
-
Method Summary
Modifier and Type Method Description Converter<?, String>stringConverter(Type type, Array<out Annotation> annotations, Retrofit retrofit)-
-
Method Detail
-
stringConverter
Converter<?, String> stringConverter(Type type, Array<out Annotation> annotations, Retrofit retrofit)
-
-
-
-