Created
August 24, 2020 18:35
-
-
Save muralidharan-rade/8fc32157efec367c7f1477cd86550518 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.muralitechblog.swagger.resource; | |
import org.springframework.web.bind.annotation.GetMapping; | |
import org.springframework.web.bind.annotation.PathVariable; | |
import org.springframework.web.bind.annotation.RequestMapping; | |
import org.springframework.web.bind.annotation.RestController; | |
@RestController | |
@RequestMapping(path = "/test") | |
public class TestResource { | |
@GetMapping(path = "/echo") | |
public String getEcho() { | |
return "Echo 1.. 2.. 3.."; | |
} | |
@GetMapping(path = "/hello/{name}") | |
public String helloApp(@PathVariable String name) { | |
return "Hello " + name; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment