Project

General

Profile

Revision 0d19c47e

ID0d19c47e70da510c44a35cf664064dfd455bd5aa
Parent 7681fbb3
Child 22244d5f

Added by Katja Luther over 4 years ago

changes for gbif/abcd import from webservice

View differences:

eu.etaxonomy.taxeditor.cdmlib/META-INF/MANIFEST.MF
82 82
 eu.etaxonomy.cdm.io.specimen,
83 83
 eu.etaxonomy.cdm.io.specimen.abcd206.in,
84 84
 eu.etaxonomy.cdm.io.specimen.excel.in,
85
 eu.etaxonomy.cdm.io.specimen.gbif.in,
85 86
 eu.etaxonomy.cdm.io.taxonx,
86 87
 eu.etaxonomy.cdm.io.tcsxml,
87 88
 eu.etaxonomy.cdm.io.tcsxml.in,
eu.etaxonomy.taxeditor.cdmlib/src/main/java/eu/etaxonomy/taxeditor/remoting/cache/CacheLoader.java
71 71
        } else if (obj instanceof Collection) {
72 72
            return (T) load((Collection<T>)obj, recursive, update);
73 73
        } else if(obj instanceof Pager) {
74
             load(((Pager)obj).getRecords(), recursive, update);
75
             return obj;
74
        	load(((Pager)obj).getRecords(), recursive, update);
75
            return obj;
76 76
        } else if(obj instanceof MergeResult) {
77 77
            return (T) load((MergeResult<CdmBase>)obj, recursive, update);
78 78
        }
......
153 153
        return map;
154 154
    }
155 155

  
156
    public <T extends Object> Collection<T> load(Collection<T> collection, boolean recursive, boolean update){
156
    public <T extends Object> Collection<T> load(Collection<T> collection,  boolean recursive, boolean update){
157 157

  
158 158
        Collection<T> loadedCollection;
159 159
        if(isRecursiveEnabled && recursive) {
......
355 355
                    CdmBase cachedCdmEntityInSubGraph = cdmCacher.getFromCache(cdmEntityInSubGraph);
356 356

  
357 357
                    if(cachedCdmEntityInSubGraph != null) {
358
                        if(cachedCdmEntityInSubGraph != cdmEntityInSubGraph) {
358
                        if(!cachedCdmEntityInSubGraph.equals(cdmEntityInSubGraph)) {
359 359
                            // exception : is the case where
360 360
                            // the field has been already initialised, cached and
361 361
                            // is not the same as the one in the cache, in which case we set the value
eu.etaxonomy.taxeditor.molecular.lib/.classpath
1 1
<?xml version="1.0" encoding="UTF-8"?>
2 2
<classpath>
3
	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
4
	<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
3 5
	<classpathentry exported="true" kind="lib" path="lib/bioinfweb-commons-bio-2.0.0-preview-1.jar"/>
4 6
	<classpathentry exported="true" kind="lib" path="lib/bioinfweb-commons-core-2.0.0-preview-1.jar"/>
5 7
	<classpathentry exported="true" kind="lib" path="lib/bioinfweb-commons-swing-2.0.0-preview-1.jar"/>
......
11 13
	<classpathentry exported="true" kind="lib" path="lib/sequencing-1.9.2-SNAPSHOT.jar"/>
12 14
	<classpathentry exported="true" kind="lib" path="lib/tic-core-2.0.0-preview-1.jar"/>
13 15
	<classpathentry exported="true" kind="lib" path="lib/tic-swt-2.0.0-preview-1.jar"/>
14
	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
15
	<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
16 16
	<classpathentry kind="output" path="target/classes"/>
17 17
</classpath>
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/io/ImportManager.java
32 32
import eu.etaxonomy.cdm.api.application.CdmApplicationState;
33 33
import eu.etaxonomy.cdm.api.application.ICdmApplicationConfiguration;
34 34
import eu.etaxonomy.cdm.common.monitor.IRemotingProgressMonitor;
35
import eu.etaxonomy.cdm.ext.occurrence.OccurenceQuery;
36 35
import eu.etaxonomy.cdm.io.common.CdmDefaultImport;
37 36
import eu.etaxonomy.cdm.io.common.IImportConfigurator;
38 37
import eu.etaxonomy.cdm.io.common.IImportConfigurator.SOURCE_TYPE;
......
43 42
import eu.etaxonomy.cdm.io.reference.endnote.in.EndnoteImportConfigurator;
44 43
import eu.etaxonomy.cdm.io.sdd.in.SDDImportConfigurator;
45 44
import eu.etaxonomy.cdm.io.service.IIOService;
45
import eu.etaxonomy.cdm.io.specimen.SpecimenImportConfiguratorBase;
46 46
import eu.etaxonomy.cdm.io.specimen.abcd206.in.Abcd206ImportConfigurator;
47
import eu.etaxonomy.cdm.io.specimen.abcd206.in.Abcd206ImportState;
47 48
import eu.etaxonomy.cdm.io.specimen.excel.in.SpecimenCdmExcelImportConfigurator;
49
import eu.etaxonomy.cdm.io.specimen.gbif.in.GbifImportConfigurator;
50
import eu.etaxonomy.cdm.io.specimen.gbif.in.GbifImportState;
48 51
import eu.etaxonomy.cdm.io.tcsxml.in.TcsXmlImportConfigurator;
49 52
import eu.etaxonomy.taxeditor.model.AbstractUtility;
50 53
import eu.etaxonomy.taxeditor.model.CdmProgressMonitorAdapter;
......
413 416

  
414 417
    }
415 418

  
416
	/*public Job createIOServiceJob(final DwcaImportConfigurator configurator) {
419
	public Job createIOServiceJob(final GbifImportConfigurator<GbifImportState, InputStream> configurator) {
417 420
		 Assert.isNotNull(configurator, "Configuration may not be null");
418 421
	        final Display display = Display.getDefault();
419 422
	        Job job = new Job("Import: " + " Dwca") {
......
440 443

  
441 444
	        return job;
442 445

  
443
	}*/
446
	}
447
	
448
	public Job createIOServiceJob(final Abcd206ImportConfigurator<Abcd206ImportState, InputStream> configurator) {
449
		 Assert.isNotNull(configurator, "Configuration may not be null");
450
	        final Display display = Display.getDefault();
451
	        Job job = new Job("Import: " + " Dwca") {
452

  
453
	            @Override
454
	            protected IStatus run(IProgressMonitor monitor) {
455
	                monitor.beginTask("Importing data", IProgressMonitor.UNKNOWN);
456
	                IIOService ioService = CdmApplicationState.getIOService();
457

  
458
	                ImportResult result = ioService.importDataFromStream(configurator);
459
	                monitor.done();
460

  
461
	                display.asyncExec(new Runnable() {
462

  
463
	                    @Override
464
	                    public void run() {
465
	                        CdmStore.getContextManager().notifyContextRefresh();
466
	                    }
467
	                });
468

  
469
	                return Status.OK_STATUS;
470
	            }
471
	        };
472

  
473
	        return job;
474

  
475
	}
476

  
477
	public Job createIOServiceJob(
478
			final List<Abcd206ImportConfigurator> abcdConfigurators) {
479
		 Assert.isNotNull(abcdConfigurators, "Configuration may not be null");
480
	        final Display display = Display.getDefault();
481
	        Job job = new Job("Import: " + " Dwca") {
482

  
483
	            @Override
484
	            protected IStatus run(IProgressMonitor monitor) {
485
	                monitor.beginTask("Importing data", IProgressMonitor.UNKNOWN);
486
	                IIOService ioService = CdmApplicationState.getIOService();
487

  
488
	                ImportResult result = ioService.importDataFromStream(abcdConfigurators);
489
	                monitor.done();
490

  
491
	                display.asyncExec(new Runnable() {
492

  
493
	                    @Override
494
	                    public void run() {
495
	                        CdmStore.getContextManager().notifyContextRefresh();
496
	                    }
497
	                });
498

  
499
	                return Status.OK_STATUS;
500
	            }
501
	        };
502

  
503
	        return job;
504
	}
505

  
506
	
444 507

  
445 508

  
446 509
}
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/io/wizard/ClassificationChooserWizardPage.java
52 52

  
53 53
	}
54 54

  
55
	protected static ClassificationChooserWizardPage createPage(){
55
	public static ClassificationChooserWizardPage createPage(){
56 56
		return new ClassificationChooserWizardPage("Configure import destinations", "Note: Selecting no classification will create a default one.");
57 57
	}
58 58

  
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/AbstractEntityCollectionElementWizardPage.java
14 14
import org.eclipse.swt.widgets.Composite;
15 15
import org.eclipse.ui.forms.widgets.TableWrapLayout;
16 16

  
17
import eu.etaxonomy.taxeditor.session.ICdmEntitySession;
18
import eu.etaxonomy.taxeditor.session.ICdmEntitySessionEnabled;
19
import eu.etaxonomy.taxeditor.store.CdmStore;
17 20
import eu.etaxonomy.taxeditor.ui.element.CdmFormFactory;
18 21
import eu.etaxonomy.taxeditor.ui.element.LayoutConstants;
19 22
import eu.etaxonomy.taxeditor.ui.element.RootElement;
23
import eu.etaxonomy.taxeditor.webapp.ICDMServerError;
20 24

  
21 25
/**
22 26
 * @author pplitzner
23 27
 * @date Mar 30, 2016
24 28
 *
25 29
 */
26
public abstract class AbstractEntityCollectionElementWizardPage extends WizardPage implements
30
public abstract class AbstractEntityCollectionElementWizardPage extends WizardPage implements 
27 31
IPropertyChangeListener {
28 32

  
29 33
    protected CdmFormFactory formFactory;
34
    
30 35

  
31 36
    protected RootElement rootElement;
32 37

  
33 38
    protected AbstractEntityCollectionElementWizardPage(String pageName) {
34 39
        super(pageName);
40
        
35 41
    }
36 42

  
37 43
    /**
......
59 65
    public void dispose() {
60 66
        rootElement.removeElements();
61 67
        formFactory.removePropertyChangeListener(this);
68
       
62 69
        super.dispose();
63 70
    }
64 71

  
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/classification/TaxonNodeDetailElement.java
173 173
				selection_reuseExistingName.setEnabled(enabled);
174 174
				if (!enabled){
175 175
                    setTaxon(selection_reuseExistingTaxon.getEntity());
176
                }
177
				if (isCreateNew()){
178
				    textNewTaxonName.setEnabled(enabled);
179
				    if (!enabled){
180
				        setTaxon(selection_reuseExistingTaxon.getEntity());
181
				    } else{
182
				        textNewTaxonName.setText(null);
183
				    }
184

  
185
				    complete = !textNewTaxonName.getText().isEmpty();
186
				}
176
                }else{
177
			        textNewTaxonName.setText(null);
178
			    }
179
				complete = !textNewTaxonName.getText().isEmpty();
180
				
187 181

  
188 182
		} else if (eventSource == selection_reuseExistingName) {
189 183
		    boolean enabled = selection_reuseExistingName.getEntity() == null;
......
291 285
	public String getTaxonName() {
292 286
        return textNewTaxonName.getText();
293 287
    }
288
	public Taxon getTaxon() {
289
        return selection_reuseExistingTaxon.getEntity();
290
    }
294 291

  
295 292
	public Reference getReference(){
296 293
	    return selection_SecRef.getSelection();
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/classification/TaxonNodeWizardPage.java
148 148
	}
149 149

  
150 150
	public Taxon createTaxon() {
151
		String taxonName = ((TaxonNodeDetailElement) getDetailElement()).getTaxonName();
152
		Reference reference = ((TaxonNodeDetailElement) getDetailElement()).getReference();
153
		NonViralName parseReferencedName = ParseHandler.parseReferencedName(taxonName, null);
154
		return Taxon.NewInstance(parseReferencedName, reference);
151
		if (((TaxonNodeDetailElement) getDetailElement()).getTaxon() == null){
152
			String taxonName = ((TaxonNodeDetailElement) getDetailElement()).getTaxonName();
153
			Reference reference = ((TaxonNodeDetailElement) getDetailElement()).getReference();
154
			NonViralName parseReferencedName = ParseHandler.parseReferencedName(taxonName, null);
155
			return Taxon.NewInstance(parseReferencedName, reference);
156
		} else{
157
			return ((TaxonNodeDetailElement) getDetailElement()).getTaxon();
158
		}
155 159
	}
156 160

  
157 161
	/*
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/description/detail/TaxonInteractionDetailElement.java
12 12

  
13 13
import org.eclipse.swt.SWT;
14 14

  
15
import eu.etaxonomy.cdm.hibernate.HibernateProxyHelper;
15 16
import eu.etaxonomy.cdm.model.description.TaxonInteraction;
16 17
import eu.etaxonomy.cdm.model.taxon.Taxon;
17 18
import eu.etaxonomy.taxeditor.store.CdmStore;
......
69 70

  
70 71
		interactionDescription = formFactory.createMultiLineTextWithLabel(this,
71 72
				"Relationship to the taxon:", 200, SWT.WRAP);
73
		entity = HibernateProxyHelper.deproxy(entity, TaxonInteraction.class);
72 74
		interactionDescription.setText(entity.getDescription(CdmStore
73 75
				.getDefaultLanguage()));
74 76
	}
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/name/NameRelationshipWizard.java
10 10

  
11 11
package eu.etaxonomy.taxeditor.ui.section.name;
12 12

  
13
import java.util.Collection;
14
import java.util.Collections;
15
import java.util.List;
16
import java.util.Map;
17

  
13 18
import org.eclipse.jface.wizard.Wizard;
14 19

  
15 20
import eu.etaxonomy.cdm.api.conversation.ConversationHolder;
16 21
import eu.etaxonomy.cdm.api.conversation.IConversationEnabled;
22
import eu.etaxonomy.cdm.model.common.CdmBase;
17 23
import eu.etaxonomy.cdm.model.name.NameRelationship;
18 24
import eu.etaxonomy.cdm.persistence.hibernate.CdmDataChangeMap;
25
import eu.etaxonomy.taxeditor.session.ICdmEntitySession;
26
import eu.etaxonomy.taxeditor.session.ICdmEntitySessionEnabled;
27
import eu.etaxonomy.taxeditor.store.CdmStore;
19 28

  
20 29
/**
21 30
 * <p>NameRelationshipWizard class.</p>
......
24 33
 * @created Jun 1, 2010
25 34
 * @version 1.0
26 35
 */
27
public class NameRelationshipWizard extends Wizard implements IConversationEnabled{
36
public class NameRelationshipWizard extends Wizard implements IConversationEnabled, ICdmEntitySessionEnabled{
28 37

  
29 38
	private static NameRelationshipDetailSection callingSection;
30 39
	
40
	private ICdmEntitySession cdmEntitySession;
41
    private ICdmEntitySession previousCdmEntitySession;
42
    private CdmBase rootElement;
43
	
31 44
	/**
32 45
	 * <p>Constructor for NameRelationshipWizard.</p>
33 46
	 *
......
35 48
	 */
36 49
	public NameRelationshipWizard(NameRelationshipDetailSection callingSection) {
37 50
		NameRelationshipWizard.callingSection = callingSection;
51
		rootElement = callingSection.getEntity();
52
		if (CdmStore.isActive() && CdmStore.getCurrentSessionManager().isRemoting()) {
53
            previousCdmEntitySession = CdmStore.getCurrentSessionManager().getActiveSession();
54
            cdmEntitySession = CdmStore.getCurrentSessionManager().newSession(this, true);
55
            cdmEntitySession.bind();
56
        }
38 57
	}
39 58
		
40 59
	private NameRelationshipWizardPage page;
......
56 75
		return page.isPageComplete();
57 76
	}
58 77

  
59

  
78
	@Override
79
    public void dispose() {
80
        super.dispose();
81
        if(cdmEntitySession != null) {
82
            cdmEntitySession.dispose();
83
        }
84
        if(previousCdmEntitySession!=null){
85
            previousCdmEntitySession.bind();
86
        }
87
    }
60 88

  
61 89
	/**
62 90
	 * <p>getNameRelationship</p>
......
78 106

  
79 107
	/** {@inheritDoc} */
80 108
	public void update(CdmDataChangeMap changeEvents) {}
109

  
110
	 @Override
111
	    public ICdmEntitySession getCdmEntitySession() {
112
	        return cdmEntitySession;
113
	    }
114

  
115
	    @Override
116
	    public java.util.Collection<CdmBase> getRootEntities() {
117
	        return Collections.singleton(rootElement);
118
	    }
119

  
120
	    @Override
121
	    public Map<Object, List<String>> getPropertyPathsMap() {
122
	        return null;
123
	    }
81 124
}
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/view/dataimport/GbifResponseImportView.java
14 14
import java.net.URISyntaxException;
15 15
import java.util.ArrayList;
16 16
import java.util.Collection;
17
import java.util.Comparator;
17 18
import java.util.HashSet;
18 19
import java.util.Set;
19 20

  
......
96 97
//        }
97 98

  
98 99
  //  }
100
    
101
   
102
    
103

  
104
	
99 105

  
100 106
}
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/view/dataimport/SaveImportedSpecimenAction.java
1 1
package eu.etaxonomy.taxeditor.view.dataimport;
2 2

  
3
import java.io.IOException;
4
import java.net.URI;
5
import java.util.ArrayList;
3 6
import java.util.Collection;
7
import java.util.Collections;
8
import java.util.Comparator;
4 9
import java.util.HashSet;
10
import java.util.List;
5 11
import java.util.Set;
6 12

  
13
import org.apache.http.client.ClientProtocolException;
7 14
import org.apache.log4j.Logger;
8 15
import org.eclipse.core.runtime.jobs.Job;
9 16
import org.eclipse.jface.action.Action;
17
import org.eclipse.jface.text.source.Annotation;
10 18
import org.eclipse.swt.widgets.Table;
11 19
import org.eclipse.swt.widgets.TableItem;
12 20
import org.eclipse.ui.IWorkbenchPart;
......
17 25
import eu.etaxonomy.cdm.api.service.IOccurrenceService;
18 26
import eu.etaxonomy.cdm.api.service.ITermService;
19 27
import eu.etaxonomy.cdm.ext.occurrence.OccurenceQuery;
28
import eu.etaxonomy.cdm.ext.occurrence.gbif.DataSetResponse;
20 29
import eu.etaxonomy.cdm.ext.occurrence.gbif.GbifDataSetProtocol;
30
import eu.etaxonomy.cdm.ext.occurrence.gbif.GbifQueryServiceWrapper;
21 31
import eu.etaxonomy.cdm.ext.occurrence.gbif.GbifResponse;
22
import eu.etaxonomy.cdm.io.dwca.in.DwcaImportConfigurator;
32
import eu.etaxonomy.cdm.io.specimen.abcd206.in.Abcd206ImportConfigurator;
33
import eu.etaxonomy.cdm.io.specimen.gbif.in.*;
23 34
import eu.etaxonomy.cdm.model.common.DefinedTermBase;
24 35
import eu.etaxonomy.cdm.model.common.ICdmBase;
25 36
import eu.etaxonomy.cdm.model.name.TaxonNameBase;
......
29 40
public class SaveImportedSpecimenAction extends Action {
30 41

  
31 42
    private final Logger logger = Logger.getLogger(SaveImportedSpecimenAction.class);
43
    
44
    private Comparator<GbifResponse> comparator;
32 45

  
33 46
    /* (non-Javadoc)
34 47
     * @see org.eclipse.jface.action.Action#run()
......
42 55
            Table table = dataImportView.getTable();
43 56
            Collection<GbifResponse> checkedResults = new HashSet<GbifResponse>();
44 57
            Object data;
45
            Set<String[]> unitIds = new HashSet<String[]>();
58
            Set<String[]> unitIdsGbif = new HashSet<String[]>();
59
            Set<String[]> unitIdsBioCase = new HashSet<String[]>();
60
            List<GbifResponse> biocaseResponses = new ArrayList<GbifResponse>();
61
            
46 62
            for(TableItem item:table.getItems()){
47 63
                if(item.getChecked()){
48 64
                    //Save Specimen
......
52 68
                	 }
53 69
                }
54 70
            }
71
            String[] tripleId ;
55 72
                for (GbifResponse response:checkedResults){
56 73
                	if (response != null){
57
                		/*String[] tripleId = response.getTripleID();
58
                		unitIds.add(tripleId);
59
	                		*/
74
                		tripleId = response.getTripleID();
75
                		
76
                		if (response.getDataSetProtocol().equals(GbifDataSetProtocol.BIOCASE)){
77
                			biocaseResponses.add(response);
78
                			
79
                		}else{
80
                			unitIdsGbif.add(tripleId);
81
                		}
82
                		
83
	                		
60 84
                	}
61 85
                }
86
                Collections.sort(biocaseResponses, getComparator()); 
87
                URI dataSetUri = null;
88
                Abcd206ImportConfigurator configuratorAbcd;
89
                List<Abcd206ImportConfigurator> abcdConfigurators = new ArrayList<Abcd206ImportConfigurator>();
90
                DataSetResponse dataSetResponse;
91
                OccurenceQuery bioCaseOccurrenceQuery = null;
92
                for (GbifResponse response: biocaseResponses){
93
                	try {
94
						dataSetResponse = new GbifQueryServiceWrapper().queryOriginalDataSet(response);
95
						dataSetUri = dataSetResponse.getEndpoint();
96
					} catch (ClientProtocolException e) {
97
						// TODO Auto-generated catch block
98
						e.printStackTrace();
99
					} catch (IOException e) {
100
						// TODO Auto-generated catch block
101
						e.printStackTrace();
102
					}
103
                	if (!response.getDataSetUri().equals(dataSetUri)){
104
                		configuratorAbcd = Abcd206ImportConfigurator.NewInstance(dataSetUri, null, false);
105
                		if (configuratorAbcd != null){
106
                			abcdConfigurators.add(configuratorAbcd);
107
                		}
108
                		unitIdsBioCase = new HashSet<String[]>();
109
                		bioCaseOccurrenceQuery = new OccurenceQuery(unitIdsBioCase);
110
                		configuratorAbcd.setOccurenceQuery(bioCaseOccurrenceQuery);
111
                	}
112
                	tripleId = response.getTripleID();
113
                	unitIdsBioCase.add(tripleId);
114
                }
115
              
116
                OccurenceQuery query = new OccurenceQuery(unitIdsGbif);
117
                GbifImportConfigurator configurator = GbifImportConfigurator.newInstance(query);
118
                configurator.setSourceReferenceTitle("Import Gbif data");
62 119
                
63
                DwcaImportConfigurator configurator = DwcaImportConfigurator.NewInstance(null, null);
64
               /* OccurenceQuery query = new OccurenceQuery(unitIds);
65
                configurator.setQuery(query);
66
               */
67
                /*Job job = CdmStore.getImportManager().createIOServiceJob(configurator);
68
                CdmStore.getImportManager().run(job);
69
                */
120
               
121
                
122
                //  configurator.setQuery(query);
123
               
124
               Job bioCaseJob = CdmStore.getImportManager().createIOServiceJob(abcdConfigurators);
125
               CdmStore.getImportManager().run(bioCaseJob);
126
               
127
               Job gbifJob = CdmStore.getImportManager().createIOServiceJob(configurator);
128
               CdmStore.getImportManager().run(gbifJob);
129
               
130
               
70 131
                
71 132
            }
72 133
        }
......
80 141
            }
81 142
        }
82 143
    }
83

  
84

  
144
     
85 145
    /* (non-Javadoc)
86 146
     * @see org.eclipse.jface.action.Action#getText()
87 147
     */
......
89 149
    public String getText() {
90 150
        return "Import";
91 151
    }
92

  
152
    
153
    private Comparator<GbifResponse> getComparator(){
154
    	if (comparator == null){
155
    		comparator = new GbifResponseComparator();
156
    	}
157
    	return comparator;
158
    }
159
    
160
    
93 161
}

Also available in: Unified diff

Add picture from clipboard (Maximum size: 40 MB)