Created
May 4, 2019 10:44
-
-
Save vasilevkin/a58cb29b2ccf482034dfed10781f9952 to your computer and use it in GitHub Desktop.
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
protocol HTTPClientService { | |
/** | |
Sends a 'get' request to a specified URL | |
- Parameter url: String of URL | |
- Returns: Optional observable Data type | |
*/ | |
func get(url: String) -> Observable<Data?> | |
/** | |
Sends a 'post' request to a specified URL | |
- Parameter url: String of URL | |
- Parameter params: Json object data | |
- Returns: Optional observable response Data type | |
*/ | |
func post(url: String, params: [String: Any]) -> Observable<Data?> | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment