renaming controllers so they all have 'Controller' suffix

This commit is contained in:
Mic 2013-01-09 21:37:28 +08:00
parent c690c9d05c
commit aeeeace8a2
8 changed files with 22 additions and 18 deletions

View file

@ -27,13 +27,13 @@ import org.springframework.web.bind.support.SessionStatus;
@Controller
@RequestMapping("/owners/new")
@SessionAttributes(types = Owner.class)
public class AddOwnerForm {
public class AddOwnerController {
private final Clinic clinic;
@Autowired
public AddOwnerForm(Clinic clinic) {
public AddOwnerController(Clinic clinic) {
this.clinic = clinic;
}

View file

@ -32,13 +32,13 @@ import org.springframework.web.bind.support.SessionStatus;
@Controller
@RequestMapping("/owners/{ownerId}/pets/new")
@SessionAttributes("pet")
public class AddPetForm {
public class AddPetController {
private final Clinic clinic;
@Autowired
public AddPetForm(Clinic clinic) {
public AddPetController(Clinic clinic) {
this.clinic = clinic;
}

View file

@ -29,13 +29,13 @@ import org.springframework.web.bind.support.SessionStatus;
@Controller
@RequestMapping("/owners/*/pets/{petId}/visits/new")
@SessionAttributes("visit")
public class AddVisitForm {
public class AddVisitController {
private final Clinic clinic;
@Autowired
public AddVisitForm(Clinic clinic) {
public AddVisitController(Clinic clinic) {
this.clinic = clinic;
}

View file

@ -27,13 +27,13 @@ import org.springframework.web.bind.support.SessionStatus;
@Controller
@RequestMapping("/owners/{ownerId}/edit")
@SessionAttributes(types = Owner.class)
public class EditOwnerForm {
public class EditOwnerController {
private final Clinic clinic;
@Autowired
public EditOwnerForm(Clinic clinic) {
public EditOwnerController(Clinic clinic) {
this.clinic = clinic;
}

View file

@ -30,13 +30,13 @@ import org.springframework.web.bind.support.SessionStatus;
@Controller
@RequestMapping("/owners/*/pets/{petId}/edit")
@SessionAttributes("pet")
public class EditPetForm {
public class EditPetController {
private final Clinic clinic;
@Autowired
public EditPetForm(Clinic clinic) {
public EditPetController(Clinic clinic) {
this.clinic = clinic;
}

View file

@ -23,13 +23,13 @@ import org.springframework.web.bind.annotation.RequestMethod;
* @author Arjen Poutsma
*/
@Controller
public class FindOwnersForm {
public class FindOwnersController {
private final Clinic clinic;
@Autowired
public FindOwnersForm(Clinic clinic) {
public FindOwnersController(Clinic clinic) {
this.clinic = clinic;
}

View file

@ -15,6 +15,10 @@
<level value="DEBUG" />
</logger>
<logger name="org.springframework.web">
<level value="DEBUG" />
</logger>
<!-- Root Logger -->

View file

@ -819,32 +819,32 @@
that is used to handle simple display-oriented URLs.
</li>
<li>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.FindOwnersForm</span>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.FindOwnersController</span>
is an annotation-driven, POJO <em>Form</em> controller that is used to search for
<strong>Owner</strong>s by last name.
</li>
<li>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.AddOwnerForm</span>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.AddOwnerController</span>
is an annotation-driven, POJO <em>Form</em> controller that is used to add a new <strong>Owner</strong>
to the system.
</li>
<li>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.EditOwnerForm</span>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.EditOwnerController</span>
is an annotation-driven, POJO <em>Form</em> controller that is used to edit an existing <strong>Owner</strong>.
A copy of the existing <strong>Owner</strong> is used for editing.
</li>
<li>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.AddPetForm</span>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.AddPetController</span>
is an annotation-driven, POJO <em>Form</em> controller that is used to add a new <strong>Pet</strong>
to an existing <strong>Owner</strong>.
</li>
<li>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.EditPetForm</span>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.EditPetController</span>
is an annotation-driven, POJO <em>Form</em> controller that is used to edit an existing <strong>Pet</strong>.
A copy of the existing <strong>Pet</strong> is used for editing.
</li>
<li>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.AddVisitForm</span>
<span style="font-weight: bold; font-style: italic;">org.springframework.samples.petclinic.web.AddVisitController</span>
is an annotation-driven, POJO <em>Form</em> controller that is used to add a new <strong>Visit</strong>
to an existing <strong>Pet</strong>.
</li>