Posts with the tag moshi:

Creating a Custom Type Adapter for Moshi

| 3 minute read | kotlin moshi
In building an app which guides a user through a process, stage by stage, we would probably use an enum to represent it. For example, consider a process which goes from NOT_STARTED, through IN_PROGRESS to one of either REJECTED or COMPLETED: The logic for moving between these stages is transparent to the app, we show different screens based on which stage a user is in. But what if the mapping of stages isn’t 1:1 on the client and the server?
 READ MORE