// Path: user-registration-application/src/main/java/com/ewolff/user_registration/domain/User.java
// public class User {
// 
// 	private String name;
// 	
// 	private String firstname;
// 	
// 	private String email;
// 	
// 	private User() {
// 	}
// 
// 	public void setName(String name) {
// 		this.name = name;
// 	}
// 
// 	public void setFirstname(String firstname) {
// 		this.firstname = firstname;
// 	}
// 
// 	public void setEmail(String email) {
// 		this.email = email;
// 	}
// 
// 	public User(String firstname, String name, String email) {
// 		super();
// 		this.firstname = firstname;
// 		this.name = name;
// 		this.email = email;
// 	}
// 
// 	public String getName() {
// 		return name;
// 	}
// 
// 	public String getFirstname() {
// 		return firstname;
// 	}
// 
// 	public String getEmail() {
// 		return email;
// 	}
// 	
// 	
// }


import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.validation.BindingResult;
import org.springframework.validation.FieldError;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.mvc.support.RedirectAttributes;
import com.ewolff.user_registration.domain.User;
import com.ewolff.user_registration.service.RegistrationService;
package com.ewolff.user_registration.web;



@Controller
public class RegistrationController {

	private Log log = LogFactory.getLog(RegistrationController.class);

	@Autowired
	private RegistrationController(RegistrationService registrationService) {
		this.registrationService = registrationService;
	}

	private RegistrationService registrationService;

	@RequestMapping(value = "/", method = RequestMethod.GET)
	public String homepage() {
		return "index";
	}

	@RequestMapping(value = "/user", method = RequestMethod.GET)
	public ModelAndView createForm() {
// Path: user-registration-application/src/main/java/com/ewolff/user_registration/domain/User.java
// public class User {
// 
// 	private String name;
// 	
// 	private String firstname;
// 	
// 	private String email;
// 	
// 	private User() {
// 	}
// 
// 	public void setName(String name) {
// 		this.name = name;
// 	}
// 
// 	public void setFirstname(String firstname) {
// 		this.firstname = firstname;
// 	}
// 
// 	public void setEmail(String email) {
// 		this.email = email;
// 	}
// 
// 	public User(String firstname, String name, String email) {
// 		super();
// 		this.firstname = firstname;
// 		this.name = name;
// 		this.email = email;
// 	}
// 
// 	public String getName() {
// 		return name;
// 	}
// 
// 	public String getFirstname() {
// 		return firstname;
// 	}
// 
// 	public String getEmail() {
// 		return email;
// 	}
// 	
// 	
// }


// Path: user-registration-application/src/main/java/com/ewolff/user_registration/web/RegistrationController.java
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.validation.BindingResult;
import org.springframework.validation.FieldError;
import org.springframework.web.bind.annotation.ModelAttribute;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.servlet.ModelAndView;
import org.springframework.web.servlet.mvc.support.RedirectAttributes;
import com.ewolff.user_registration.domain.User;
import com.ewolff.user_registration.service.RegistrationService;

package com.ewolff.user_registration.web;



@Controller
public class RegistrationController {

	private Log log = LogFactory.getLog(RegistrationController.class);

	@Autowired
	private RegistrationController(RegistrationService registrationService) {
		this.registrationService = registrationService;
	}

	private RegistrationService registrationService;

	@RequestMapping(value = "/", method = RequestMethod.GET)
	public String homepage() {
		return "index";
	}

	@RequestMapping(value = "/user", method = RequestMethod.GET)
	public ModelAndView createForm() {
		return new ModelAndView("user/form", "user", new User("", "", ""));