Adding JMCR-Stable version
[Benchmarks_CSolver.git] / JMCR-Stable / real-world application / derby-10.3.2.1 / java / shared / org / apache / derby / shared / common / reference / JDBC40Translation.java
diff --git a/JMCR-Stable/real-world application/derby-10.3.2.1/java/shared/org/apache/derby/shared/common/reference/JDBC40Translation.java b/JMCR-Stable/real-world application/derby-10.3.2.1/java/shared/org/apache/derby/shared/common/reference/JDBC40Translation.java
new file mode 100644 (file)
index 0000000..6eafd06
--- /dev/null
@@ -0,0 +1,65 @@
+/*\r
+\r
+   Derby - Class org.apache.derby.shared.common.reference.JDBC40Translation\r
+\r
+   Licensed to the Apache Software Foundation (ASF) under one or more\r
+   contributor license agreements.  See the NOTICE file distributed with\r
+   this work for additional information regarding copyright ownership.\r
+   The ASF licenses this file to you under the Apache License, Version 2.0\r
+   (the "License"); you may not use this file except in compliance with\r
+   the License.  You may obtain a copy of the License at\r
+\r
+      http://www.apache.org/licenses/LICENSE-2.0\r
+\r
+   Unless required by applicable law or agreed to in writing, software\r
+   distributed under the License is distributed on an "AS IS" BASIS,\r
+   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r
+   See the License for the specific language governing permissions and\r
+   limitations under the License.\r
+\r
+ */\r
+\r
+package org.apache.derby.shared.common.reference;\r
+\r
+/**\r
+        This class contains public statics that map directly to the\r
+        new public statics in the jdbc 4.0 interfaces.  By providing\r
+        an intermediary class with hard-coded copies of constants that\r
+        will be available in jdbc 4.0, it becomes possible to refer to\r
+        these constants when compiling against older jdk versions.\r
+\r
+        <P>The test <code>jdbc4/JDBC40TranslationTest.junit</code>,\r
+        which is compiled against jdk16, contains tests that verifies\r
+        that these hard coded constants are in fact equal to those\r
+        found in jdk16.\r
+\r
+        <P>\r
+        This class should not be shipped with the product.\r
+\r
+        <P>\r
+        This class has no methods, all it contains are constants\r
+        are public, static and final since they are declared in an interface.\r
+*/\r
+\r
+public interface JDBC40Translation {\r
+    /*\r
+    ** public statics from 4.0 version of java.sql.DatabaseMetaData\r
+    */\r
+    public static final int FUNCTION_PARAMETER_UNKNOWN = 0;\r
+    public static final int FUNCTION_PARAMETER_IN      = 1;\r
+    public static final int FUNCTION_PARAMETER_INOUT   = 2;\r
+    public static final int FUNCTION_PARAMETER_OUT     = 3;\r
+    public static final int FUNCTION_RETURN            = 4;\r
+    \r
+    public static final int FUNCTION_NO_NULLS          = 0;\r
+    public static final int FUNCTION_NULLABLE          = 1;\r
+    public static final int FUNCTION_NULLABLE_UNKNOWN  = 2;\r
+\r
+    // constants from java.sql.Types\r
+    public static final int NCHAR = -15;\r
+    public static final int NVARCHAR = -9;\r
+    public static final int LONGNVARCHAR = -16;\r
+    public static final int NCLOB = 2011;\r
+    public static final int ROWID = -8;\r
+    public static final int SQLXML = 2009;\r
+}\r