01: /*
02: * Licensed to the Apache Software Foundation (ASF) under one or more
03: * contributor license agreements. See the NOTICE file distributed with
04: * this work for additional information regarding copyright ownership.
05: * The ASF licenses this file to You under the Apache License, Version 2.0
06: * (the "License"); you may not use this file except in compliance with
07: * the License. You may obtain a copy of the License at
08: *
09: * http://www.apache.org/licenses/LICENSE-2.0
10: *
11: * Unless required by applicable law or agreed to in writing, software
12: * distributed under the License is distributed on an "AS IS" BASIS,
13: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14: * See the License for the specific language governing permissions and
15: * limitations under the License.
16: */
17:
18: package javax.sql.rowset.spi;
19:
20: import javax.sql.RowSetReader;
21: import javax.sql.RowSetWriter;
22:
23: public abstract class SyncProvider {
24: public static int GRADE_NONE = 1;
25:
26: public static int GRADE_CHECK_MODIFIED_AT_COMMIT = 2;
27:
28: public static int GRADE_CHECK_ALL_AT_COMMIT = 3;
29:
30: public static int GRADE_LOCK_WHEN_MODIFIED = 4;
31:
32: public static int GRADE_LOCK_WHEN_LOADED = 5;
33:
34: public static int DATASOURCE_NO_LOCK = 1;
35:
36: public static int DATASOURCE_ROW_LOCK = 2;
37:
38: public static int DATASOURCE_TABLE_LOCK = 3;
39:
40: public static int DATASOURCE_DB_LOCK = 4;
41:
42: public static int UPDATABLE_VIEW_SYNC = 5;
43:
44: public static int NONUPDATABLE_VIEW_SYNC = 6;
45:
46: public SyncProvider() {
47: super ();
48: }
49:
50: public abstract String getProviderID();
51:
52: public abstract RowSetReader getRowSetReader();
53:
54: public abstract RowSetWriter getRowSetWriter();
55:
56: public abstract int getProviderGrade();
57:
58: public abstract void setDataSourceLock(int dataSourceLock)
59: throws SyncProviderException;
60:
61: public abstract int getDataSourceLock()
62: throws SyncProviderException;
63:
64: public abstract int supportsUpdatableView();
65:
66: public abstract String getVersion();
67:
68: public abstract String getVendor();
69: }
|