01: /*
02: * GeoTools - OpenSource mapping toolkit
03: * http://geotools.org
04: * (C) 2002-2006, GeoTools Project Managment Committee (PMC)
05: *
06: * This library is free software; you can redistribute it and/or
07: * modify it under the terms of the GNU Lesser General Public
08: * License as published by the Free Software Foundation;
09: * version 2.1 of the License.
10: *
11: * This library is distributed in the hope that it will be useful,
12: * but WITHOUT ANY WARRANTY; without even the implied warranty of
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14: * Lesser General Public License for more details.
15: */
16: package org.geotools.data;
17:
18: import java.io.IOException;
19:
20: /**
21: * A data store that can version enable feature types, and then keep version
22: * history for those.
23: * TODO: add better docs on how to leverage featureVersion in standard queries,
24: * as well as
25: *
26: * @author Andrea Aime, TOPP
27: */
28: public interface VersioningDataStore extends DataStore {
29: /**
30: * Returns true if the specified feature type is versioned, false otherwise
31: *
32: * @param typeName
33: * @return
34: */
35: public boolean isVersioned(String typeName) throws IOException;
36:
37: /**
38: * Alters the versioned state of a feature type
39: *
40: * @param typeName
41: * the type name that must be changed
42: * @param versioned
43: * if true, the type gets version enabled, if false versioning is
44: * disabled
45: * @param t
46: * the transaction used to performe version enabling. It shall
47: * contain user and commit message as properties.
48: * @throws IOException
49: */
50: public void setVersioned(String typeName, boolean versioned,
51: String author, String message) throws IOException;
52: }
|