@Controller
public class MainApp
extends java.lang.Object
Constructor and Description |
---|
MainApp() |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getApplicationPage()
getApplicationPage do redirects to /game URL
|
java.lang.String |
getIndex(org.springframework.ui.Model model)
getIndex returns an html that shows main page of application
|
void |
sendCode(java.security.Principal principal)
sendCode method, receives petition to generate 4 digits code and returns
it to client-side
|
@GetMapping(value="/") public java.lang.String getIndex(org.springframework.ui.Model model)
model
- @MessageMapping(value="/fourCode") public void sendCode(java.security.Principal principal)
principal
- Users that do that petitionpublic java.lang.String getApplicationPage()