Project

General

Profile

Download (1.4 KB) Statistics
| Branch: | Tag: | Revision:
1
// $Id$
2
/**
3
* Copyright (C) 2017 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
package eu.etaxonomy.cdm.vaadin.util;
11

    
12
import java.util.List;
13
import java.util.UUID;
14

    
15
import org.vaadin.addons.lazyquerycontainer.LazyQueryDefinition;
16

    
17
import eu.etaxonomy.cdm.api.application.CdmRepository;
18
import eu.etaxonomy.cdm.model.location.NamedArea;
19

    
20
/**
21
 * @author freimeier
22
 * @date 22.11.2017
23
 *
24
 */
25
public class DistributionStatusQueryDefinition extends LazyQueryDefinition {
26

    
27
    private CdmRepository repo;
28
    private List<UUID> nodeUuids;
29
    private List<NamedArea> namedAreas;
30

    
31
    /**
32
     * @param repo
33
     * @param nodeUuids
34
     * @param namedAreas
35
     * @param compositeItems
36
     * @param batchSize
37
     * @param idPropertyId
38
     */
39
    public DistributionStatusQueryDefinition(List<NamedArea> namedAreas,
40
            boolean compositeItems, int batchSize) {
41
        super(compositeItems, batchSize, DistributionStatusQuery.UUID_COLUMN);
42
        this.addProperty(DistributionStatusQuery.UUID_COLUMN, UUID.class, null, true, false);
43
        this.addProperty(DistributionStatusQuery.TAXON_COLUMN, String.class, null, true, false);
44
        namedAreas.forEach(na -> this.addProperty(na.getUuid(), UUID.class, null, false, false));
45
    }
46
}
(11-11/15)