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.cdm.io.common;
|
12
|
|
13
|
import java.sql.ResultSet;
|
14
|
import java.util.Map;
|
15
|
|
16
|
import org.springframework.transaction.TransactionStatus;
|
17
|
|
18
|
import eu.etaxonomy.cdm.model.common.CdmBase;
|
19
|
|
20
|
|
21
|
/**
|
22
|
* @author a.mueller
|
23
|
* @created 16.02.2010
|
24
|
* @version 1.0
|
25
|
*/
|
26
|
public interface IPartitionedIO<STATE extends IPartitionedState> {
|
27
|
|
28
|
public final String ID_LIST_TOKEN = "@IdList";
|
29
|
|
30
|
//TODO make state more generic
|
31
|
public boolean doPartition(ResultSetPartitioner partitioner, STATE state);
|
32
|
|
33
|
public TransactionStatus startTransaction();
|
34
|
|
35
|
public void commitTransaction(TransactionStatus txStatus);
|
36
|
|
37
|
public String getPluralString();
|
38
|
|
39
|
/**
|
40
|
* @param rs
|
41
|
* @return
|
42
|
*/
|
43
|
public Map<Object, Map<String, ? extends CdmBase>> getRelatedObjectsForPartition(ResultSet rs);
|
44
|
}
|