Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class LoginController extends Controller {
- @Inject
- FormFactory formFactory;
- @Inject
- UserFactory userFactory;
- public Result loginPage(){
- Form loginForm = formFactory.form(models.UserFactory.User.class);
- return ok(login.render(loginForm));
- }
- public class UserFactory {
- @Inject Database db;
- public class User {
- private int id;
- private String username;
- private String password;
- private String email;
- public User(){
- }
- public User(int id, String username, String password, String email){
- this.id = id;
- this.username = username;
- this.password = password;
- this.email = email;
- }
- public UserFactory(){
- }
- }}
- //all other functions i do not copy, because they do not cause an error
Add Comment
Please, Sign In to add comment