Created
February 6, 2018 15:41
-
-
Save rhari991/03adf3109571931febab53de5c1122a7 to your computer and use it in GitHub Desktop.
A sample way to define a Retrofit interface for multiple required and optional request arguments
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public interface MyApiService { | |
public Call<String> method(String requiredArgument1); | |
public Call<String> method(String requiredArgument1, String optionalArgument1); | |
public Call<String> method(String requiredArgument1, String optionalArgument1, String optionalArgument2); | |
//Add every possible combination of arguments | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment