Project

General

Profile

« Previous | Next » 

Revision 008ebe8f

Added by Patrick Plitzner over 6 years ago

ref #7006 Migrate store preferences

View differences:

eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/preference/matching/TeamOrPersonMatchingPreference.java
9 9

  
10 10
package eu.etaxonomy.taxeditor.preference.matching;
11 11

  
12
import org.eclipse.ui.IWorkbench;
13

  
14 12
import eu.etaxonomy.cdm.model.agent.TeamOrPersonBase;
13
import eu.etaxonomy.cdm.model.common.CdmBase;
15 14
import eu.etaxonomy.cdm.strategy.match.IMatchStrategy;
16 15
import eu.etaxonomy.cdm.strategy.match.MatchException;
17 16
import eu.etaxonomy.cdm.strategy.match.MatchStrategyConfigurator;
18
import eu.etaxonomy.taxeditor.model.MessagingUtils;
19 17

  
20 18
/**
21 19
 * @author n.hoffmann
......
25 23
public class TeamOrPersonMatchingPreference extends
26 24
		AbstractMatchingPreferences<TeamOrPersonBase> {
27 25

  
28
	/** {@inheritDoc} */
29
	@Override
30
    public void init(IWorkbench workbench) {
31
	    super.init(workbench);
32
		clazz = TeamOrPersonBase.class;
33 26

  
34
		try {
35
			matchStrategy = MatchStrategyConfigurator.TeamOrPersonMatchStrategy();
36
		} catch (MatchException e) {
37
			MessagingUtils.error(this.getClass(), e);
38
			throw new RuntimeException(e);
39
		}
40
	}
27
    @Override
28
    public Class<? extends CdmBase> getType(){
29
        return TeamOrPersonBase.class;
30
    }
41 31

  
42 32
	/** {@inheritDoc} */
43 33
	@Override

Also available in: Unified diff