@CrossOrigin
@RestController
@RequestMapping(value="/question")
public class QuestionRestController
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
(package private) QuestionCRUDController |
questionCRUDController |
Constructor and Description |
---|
QuestionRestController() |
Modifier and Type | Method and Description |
---|---|
org.springframework.http.ResponseEntity<QuestionCrudDTO> |
createQuestionDTO(QuestionDTO questionDTO) |
org.springframework.http.ResponseEntity<QuestionCrudDTO> |
deleteQuestionDTO(java.lang.String id) |
org.springframework.http.ResponseEntity<QuestionCrudDTO> |
getCountQuestionByState(java.lang.String state,
java.lang.String userId) |
org.springframework.http.ResponseEntity<QuestionCrudDTO> |
getQuestionDTO(java.lang.String id,
java.lang.String creatorId,
java.lang.String focus,
java.lang.String subject,
java.lang.String tag,
java.lang.String recent,
java.lang.String approved,
java.lang.String state) |
org.springframework.http.ResponseEntity<QuestionCrudDTO> |
updateQuestionDTO(QuestionDTO questionDTO) |
@Autowired QuestionCRUDController questionCRUDController
@RequestMapping(method=GET) public org.springframework.http.ResponseEntity<QuestionCrudDTO> getQuestionDTO(@RequestParam(value="id",defaultValue="NA") java.lang.String id, @RequestParam(value="creatorId",defaultValue="NA") java.lang.String creatorId, @RequestParam(value="focus",defaultValue="NA") java.lang.String focus, @RequestParam(value="subject",defaultValue="NA") java.lang.String subject, @RequestParam(value="tag",defaultValue="NA") java.lang.String tag, @RequestParam(value="recent",defaultValue="false") java.lang.String recent, @RequestParam(value="approved",defaultValue="false") java.lang.String approved, @RequestParam(value="state",defaultValue="NA") java.lang.String state)
@RequestMapping(value="/count", method=GET) public org.springframework.http.ResponseEntity<QuestionCrudDTO> getCountQuestionByState(@RequestParam(value="state") java.lang.String state, @RequestParam(value="userid") java.lang.String userId)
@RequestMapping(method=DELETE) public org.springframework.http.ResponseEntity<QuestionCrudDTO> deleteQuestionDTO(@RequestParam(value="id",defaultValue="NA") java.lang.String id)
@RequestMapping(method=PUT) public org.springframework.http.ResponseEntity<QuestionCrudDTO> updateQuestionDTO(@RequestBody QuestionDTO questionDTO)
@RequestMapping(method=POST) public org.springframework.http.ResponseEntity<QuestionCrudDTO> createQuestionDTO(@RequestBody QuestionDTO questionDTO)