Skip to content

Instantly share code, notes, and snippets.

@HDBandit
Created February 13, 2016 20:51
Show Gist options
  • Save HDBandit/60752cb84813b59cd13c to your computer and use it in GitHub Desktop.
Save HDBandit/60752cb84813b59cd13c to your computer and use it in GitHub Desktop.
@RestController
@RequestMapping("/task")
public class TaskController {
@RequestMapping(method = RequestMethod.POST)
public void createTask(@RequestBody CreateTaskRequest createTaskRequest) {
if (TaskType.GROUP.equals(createTaskRequest.getType())) {
System.out.println("Creating group task");
}
if (TaskType.USER.equals(createTaskRequest.getType())) {
System.out.print("Creating user task");
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment