performed javacscript:fix and worked on documentation
[taxeditor.git] / taxeditor-editor / src / main / java / eu / etaxonomy / taxeditor / editor / newWizard / NewPersonWizard.java
1 // $Id$
2 /**
3 * Copyright (C) 2007 EDIT
4 * European Distributed Institute of Taxonomy
5 * http://www.e-taxonomy.eu
6 *
7 * The contents of this file are subject to the Mozilla Public License Version 1.1
8 * See LICENSE.TXT at the top of this package for the full license terms.
9 */
10
11 package eu.etaxonomy.taxeditor.editor.newWizard;
12
13 import org.apache.log4j.Logger;
14
15 import eu.etaxonomy.cdm.model.agent.Person;
16 import eu.etaxonomy.taxeditor.section.agent.PersonWizardPage;
17 import eu.etaxonomy.taxeditor.store.CdmStore;
18
19 /**
20 * <p>NewPersonWizard class.</p>
21 *
22 * @author n.hoffmann
23 * @created Jun 1, 2010
24 * @version 1.0
25 */
26 public class NewPersonWizard extends AbstractNewEntityWizard<Person> {
27 private static final Logger logger = Logger
28 .getLogger(NewPersonWizard.class);
29
30 /** {@inheritDoc} */
31 @Override
32 public void addPages() {
33 addPage(new PersonWizardPage(formFactory, getConversationHolder(), entity));
34 }
35
36 /** {@inheritDoc} */
37 @Override
38 protected Person createNewEntity() {
39 return Person.NewTitledInstance("");
40 }
41
42 /** {@inheritDoc} */
43 @Override
44 protected void saveEntity() {
45 CdmStore.getAgentService().saveOrUpdate(entity);
46 }
47 }