Created
July 30, 2019 10:22
-
-
Save abhishek-sisodiya/8c9daab4d98ad84899881a0239dc77e2 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
package com.org.project.theWeatherMan.controller; | |
/** | |
* This controller class handle request/response for average of all providers. | |
* | |
* @author abhishek.sisodiya | |
* @since 03/07/2019. | |
*/ | |
@RestController | |
public class AverageProviderController { | |
@Autowired | |
private AverageProviderService averageProviderService; | |
@ApiOperation(value = "Average of all the providers.") | |
@RequestMapping(value = "/averageprovider", method = RequestMethod.GET) | |
public ResponseEntity getAverageOfProviders(@RequestParam String latLong) | |
throws Exception { | |
return new ResponseEntity( | |
new CustomResponseEntity().getResponseObject(averageProviderService.averageProvider(latLong)), | |
HttpStatus.OK); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment