what-the-bank/sources/retrofit2/converter/scalars/ScalarRequestBodyConverter....

28 lines
1.0 KiB
Java

package retrofit2.converter.scalars;
import java.io.IOException;
import okhttp3.MediaType;
import okhttp3.RequestBody;
import retrofit2.Converter;
/* loaded from: classes.dex */
final class ScalarRequestBodyConverter<T> implements Converter<T, RequestBody> {
static final ScalarRequestBodyConverter<Object> INSTANCE = new ScalarRequestBodyConverter<>();
private static final MediaType MEDIA_TYPE = MediaType.get("text/plain; charset=UTF-8");
/* JADX WARN: Multi-variable type inference failed */
@Override // retrofit2.Converter
public final /* bridge */ /* synthetic */ RequestBody convert(Object obj) throws IOException {
return convert2((ScalarRequestBodyConverter<T>) obj);
}
private ScalarRequestBodyConverter() {
}
@Override // retrofit2.Converter
/* renamed from: convert, reason: avoid collision after fix types in other method */
public final RequestBody convert2(T t) throws IOException {
return RequestBody.create(MEDIA_TYPE, String.valueOf(t));
}
}