提交 4830b307 authored 作者: Thomas Mueller's avatar Thomas Mueller

--no commit message

--no commit message
上级 faecae21
...@@ -111,9 +111,10 @@ ...@@ -111,9 +111,10 @@
</target> </target>
<target name="compileServlet" depends="compileServletTest, compile" if="servlet.jar.present"> <target name="compileServlet" depends="compileServletTest, compile" if="servlet.jar.present">
<javac target="${jdk}" source="${jdk}" executable="${javac}" srcdir="src/tools" destdir="bin" debug="true"> <javac target="${jdk}" source="${jdk}" executable="${javac}" srcdir="src/main" destdir="bin" debug="true">
<classpath location="${path.servlet.jar}" /> <classpath location="${path.servlet.jar}" />
<include name="org/h2/server/web/*.*"/> <include name="org/h2/server/web/WebServlet.java"/>
<include name="org/h2/server/web/DbStarter.java"/>
</javac> </javac>
</target> </target>
...@@ -125,11 +126,11 @@ ...@@ -125,11 +126,11 @@
<target name="compile" depends="compileResources, compileTest"> <target name="compile" depends="compileResources, compileTest">
<javac target="${jdk}" source="${jdk}" executable="${javac}" srcdir="src/main" destdir="bin" debug="true"> <javac target="${jdk}" source="${jdk}" executable="${javac}" srcdir="src/main" destdir="bin" debug="true">
<exclude name="org/h2/fulltext/FullTextLucene.java"/> <exclude name="org/h2/fulltext/FullTextLucene.java"/>
<exclude name="org/h2/server/web/WebServlet.java"/>
<exclude name="org/h2/server/web/DbStarter.java"/>
</javac> </javac>
<javac target="${jdk}" source="${jdk}" executable="${javac}" srcdir="src/test" destdir="bin" debug="true"/> <javac target="${jdk}" source="${jdk}" executable="${javac}" srcdir="src/test" destdir="bin" debug="true"/>
<javac target="${jdk}" source="${jdk}" executable="${javac}" srcdir="src/tools" destdir="bin" debug="true"> <javac target="${jdk}" source="${jdk}" executable="${javac}" srcdir="src/tools" destdir="bin" debug="true"/>
<exclude name="org/h2/server/web/*.*"/>
</javac>
<copy todir="bin" overwrite="true"> <copy todir="bin" overwrite="true">
<fileset dir="src/main" includes="META-INF/**/*"/> <fileset dir="src/main" includes="META-INF/**/*"/>
<fileset dir="src/main" includes="**/*.png"/> <fileset dir="src/main" includes="**/*.png"/>
......
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<!-- <!--
Copyright 2004-2007 H2 Group. Licensed under the H2 License, Version 1.0 (http://h2database.com/html/license.html). Copyright 2004-2007 H2 Group. Licensed under the H2 License, Version 1.0 (http://h2database.com/html/license.html).
Initial Developer: H2 Group Initial Developer: H2 Group
--> -->
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"> <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
...@@ -21,7 +21,7 @@ H2 Database Engine ...@@ -21,7 +21,7 @@ H2 Database Engine
<a href="http://www.h2database.com/h2-2007-12-02.zip">Platform-Independent Zip</a><br /> <a href="http://www.h2database.com/h2-2007-12-02.zip">Platform-Independent Zip</a><br />
</p> </p>
<h3>Download Mirror</h3> <h3>Download Mirror and Older Versions</h3>
<p> <p>
<a href="http://code.google.com/p/h2database/downloads/list">Platform-Independent Zip</a><br /> <a href="http://code.google.com/p/h2database/downloads/list">Platform-Independent Zip</a><br />
</p> </p>
......
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -154,6 +154,7 @@ ...@@ -154,6 +154,7 @@
90131=Concurrent update in table {0}\: another transaction has updated or deleted the same row 90131=Concurrent update in table {0}\: another transaction has updated or deleted the same row
90132=Aggregate {0} not found 90132=Aggregate {0} not found
90133=Cannot change the setting {0} when the database is already open 90133=Cannot change the setting {0} when the database is already open
90134=Access to the class {0} is denied
HY000=General error\: {0} HY000=General error\: {0}
HY004=Unknown data type\: {0} HY004=Unknown data type\: {0}
HYC00=Feature not supported HYC00=Feature not supported
......
...@@ -22,7 +22,7 @@ import org.h2.util.StringCache; ...@@ -22,7 +22,7 @@ import org.h2.util.StringCache;
import org.h2.util.StringUtils; import org.h2.util.StringUtils;
/** /**
* This class can read a file that is similar to BNF (BackusNaur form). * This class can read a file that is similar to BNF (Backus-Naur form).
* It is made specially to support SQL grammar. * It is made specially to support SQL grammar.
*/ */
public class Bnf { public class Bnf {
......
...@@ -314,6 +314,7 @@ public class ErrorCode { ...@@ -314,6 +314,7 @@ public class ErrorCode {
public static final int CONCURRENT_UPDATE_1 = 90131; public static final int CONCURRENT_UPDATE_1 = 90131;
public static final int AGGREGATE_NOT_FOUND_1 = 90132; public static final int AGGREGATE_NOT_FOUND_1 = 90132;
public static final int CANNOT_CHANGE_SETTING_WHEN_OPEN_1 = 90133; public static final int CANNOT_CHANGE_SETTING_WHEN_OPEN_1 = 90133;
public static final int ACCESS_DENIED_TO_CLASS_1 = 90134;
/** /**
* INTERNAL * INTERNAL
......
...@@ -71,6 +71,7 @@ public class SysProperties { ...@@ -71,6 +71,7 @@ public class SysProperties {
public static final int LOB_FILES_PER_DIRECTORY = getIntSetting("h2.lobFilesPerDirectory", 256); public static final int LOB_FILES_PER_DIRECTORY = getIntSetting("h2.lobFilesPerDirectory", 256);
public static final boolean NEW_DISPLAY_SIZE = getBooleanSetting("h2.newDisplaySize", true); public static final boolean NEW_DISPLAY_SIZE = getBooleanSetting("h2.newDisplaySize", true);
public static final int DEFAULT_MAX_OPERATION_MEMORY = getIntSetting("h2.defaultMaxOperationMemory", 100000); public static final int DEFAULT_MAX_OPERATION_MEMORY = getIntSetting("h2.defaultMaxOperationMemory", 100000);
public static final String ALLOWED_CLASSES = getStringSetting("h2.allowedClasses", "*");
private static boolean getBooleanSetting(String name, boolean defaultValue) { private static boolean getBooleanSetting(String name, boolean defaultValue) {
String s = getProperty(name); String s = getProperty(name);
......
...@@ -17,7 +17,7 @@ import org.h2.table.Column; ...@@ -17,7 +17,7 @@ import org.h2.table.Column;
import org.h2.table.Table; import org.h2.table.Table;
/** /**
* The base calss for constraint checking. * The base class for constraint checking.
*/ */
public abstract class Constraint extends SchemaObjectBase { public abstract class Constraint extends SchemaObjectBase {
......
...@@ -20,7 +20,7 @@ import org.h2.table.TableFilter; ...@@ -20,7 +20,7 @@ import org.h2.table.TableFilter;
import org.h2.util.StringUtils; import org.h2.util.StringUtils;
/** /**
* A check contraint. * A check constraint.
*/ */
public class ConstraintCheck extends Constraint { public class ConstraintCheck extends Constraint {
......
...@@ -27,7 +27,7 @@ import org.h2.value.Value; ...@@ -27,7 +27,7 @@ import org.h2.value.Value;
import org.h2.value.ValueNull; import org.h2.value.ValueNull;
/** /**
* A referential contraint. * A referential constraint.
*/ */
public class ConstraintReferential extends Constraint { public class ConstraintReferential extends Constraint {
public static final int RESTRICT = 0, CASCADE = 1, SET_DEFAULT = 2, SET_NULL = 3; public static final int RESTRICT = 0, CASCADE = 1, SET_DEFAULT = 2, SET_NULL = 3;
......
...@@ -15,7 +15,7 @@ import org.h2.table.Table; ...@@ -15,7 +15,7 @@ import org.h2.table.Table;
import org.h2.util.StringUtils; import org.h2.util.StringUtils;
/** /**
* A unique contraint. This object always backed by a unique index. * A unique constraint. This object always backed by a unique index.
*/ */
public class ConstraintUnique extends Constraint { public class ConstraintUnique extends Constraint {
......
...@@ -1295,9 +1295,9 @@ public class Database implements DataHandler { ...@@ -1295,9 +1295,9 @@ public class Database implements DataHandler {
} }
} }
public Class loadClass(String className) throws SQLException { public Class loadUserClass(String className) throws SQLException {
try { try {
return ClassUtils.loadClass(className); return ClassUtils.loadUserClass(className);
} catch (ClassNotFoundException e) { } catch (ClassNotFoundException e) {
throw Message.getSQLException(ErrorCode.CLASS_NOT_FOUND_1, new String[] { className }, e); throw Message.getSQLException(ErrorCode.CLASS_NOT_FOUND_1, new String[] { className }, e);
} }
...@@ -1308,7 +1308,7 @@ public class Database implements DataHandler { ...@@ -1308,7 +1308,7 @@ public class Database implements DataHandler {
eventListener = null; eventListener = null;
} else { } else {
try { try {
eventListener = (DatabaseEventListener) loadClass(className).newInstance(); eventListener = (DatabaseEventListener) loadUserClass(className).newInstance();
String url = databaseURL; String url = databaseURL;
if (cipher != null) { if (cipher != null) {
url += ";CIPHER=" + cipher; url += ";CIPHER=" + cipher;
......
...@@ -55,7 +55,7 @@ public class FunctionAlias extends DbObjectBase { ...@@ -55,7 +55,7 @@ public class FunctionAlias extends DbObjectBase {
if (javaMethod != null) { if (javaMethod != null) {
return; return;
} }
Class javaClass = database.loadClass(className); Class javaClass = database.loadUserClass(className);
Method[] methods = javaClass.getMethods(); Method[] methods = javaClass.getMethods();
for (int i = 0; i < methods.length; i++) { for (int i = 0; i < methods.length; i++) {
Method m = methods[i]; Method m = methods[i];
......
...@@ -30,7 +30,7 @@ public class UserAggregate extends DbObjectBase { ...@@ -30,7 +30,7 @@ public class UserAggregate extends DbObjectBase {
public AggregateFunction getInstance() throws SQLException { public AggregateFunction getInstance() throws SQLException {
if (javaClass == null) { if (javaClass == null) {
javaClass = database.loadClass(className); javaClass = database.loadUserClass(className);
} }
Object obj; Object obj;
try { try {
......
...@@ -22,7 +22,7 @@ import org.h2.value.Value; ...@@ -22,7 +22,7 @@ import org.h2.value.Value;
import org.h2.value.ValueNull; import org.h2.value.ValueNull;
/** /**
* This class wrapps a user defined aggregate. * This class wraps a user defined aggregate.
*/ */
public class JavaAggregate extends Expression { public class JavaAggregate extends Expression {
......
...@@ -16,7 +16,7 @@ import org.h2.value.ValueNull; ...@@ -16,7 +16,7 @@ import org.h2.value.ValueNull;
import org.h2.value.ValueResultSet; import org.h2.value.ValueResultSet;
/** /**
* This class wrapps a user defined function. * This class wraps a user defined function.
*/ */
public class JavaFunction extends Expression implements FunctionCall { public class JavaFunction extends Expression implements FunctionCall {
......
...@@ -59,9 +59,9 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -59,9 +59,9 @@ public class JdbcConnection extends TraceObject implements Connection {
private String url; private String url;
private String user; private String user;
private int holdability = 1; // ResultSet.HOLD_CURSORS_OVER_COMMIT private int holdability = 1; // ResultSet.HOLD_CURSORS_OVER_COMMIT
private SessionInterface session; private SessionInterface session;
private CommandInterface commit, rollback; private CommandInterface commit, rollback;
private CommandInterface setAutoCommitTrue, setAutoCommitFalse, getAutoCommit; private CommandInterface setAutoCommitTrue, setAutoCommitFalse, getAutoCommit;
...@@ -131,7 +131,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -131,7 +131,7 @@ public class JdbcConnection extends TraceObject implements Connection {
try { try {
int id = getNextId(TraceObject.STATEMENT); int id = getNextId(TraceObject.STATEMENT);
if (debug()) { if (debug()) {
debugCodeAssign("Statement", TraceObject.STATEMENT, id, debugCodeAssign("Statement", TraceObject.STATEMENT, id,
"createStatement(" + resultSetType + ", " + resultSetConcurrency + ", " + resultSetHoldability + ")"); "createStatement(" + resultSetType + ", " + resultSetConcurrency + ", " + resultSetHoldability + ")");
} }
checkClosed(); checkClosed();
...@@ -311,7 +311,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -311,7 +311,7 @@ public class JdbcConnection extends TraceObject implements Connection {
throw logAndConvert(e); throw logAndConvert(e);
} }
} }
private boolean getInternalAutoCommit() throws SQLException { private boolean getInternalAutoCommit() throws SQLException {
getAutoCommit = prepareCommand("CALL AUTOCOMMIT()", getAutoCommit); getAutoCommit = prepareCommand("CALL AUTOCOMMIT()", getAutoCommit);
ResultInterface result = getAutoCommit.executeQuery(0, false); ResultInterface result = getAutoCommit.executeQuery(0, false);
...@@ -716,7 +716,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -716,7 +716,7 @@ public class JdbcConnection extends TraceObject implements Connection {
try { try {
int id = getNextId(TraceObject.CALLABLE_STATEMENT); int id = getNextId(TraceObject.CALLABLE_STATEMENT);
if (debug()) { if (debug()) {
debugCodeAssign("CallableStatement", TraceObject.CALLABLE_STATEMENT, id, debugCodeAssign("CallableStatement", TraceObject.CALLABLE_STATEMENT, id,
"prepareCall(" + quote(sql) + ", " + resultSetType + ", " + resultSetConcurrency + ", " "prepareCall(" + quote(sql) + ", " + resultSetType + ", " + resultSetConcurrency + ", "
+ resultSetHoldability + ")"); + resultSetHoldability + ")");
} }
...@@ -826,7 +826,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -826,7 +826,7 @@ public class JdbcConnection extends TraceObject implements Connection {
try { try {
int id = getNextId(TraceObject.PREPARED_STATEMENT); int id = getNextId(TraceObject.PREPARED_STATEMENT);
if (debug()) { if (debug()) {
debugCodeAssign("PreparedStatement", TraceObject.PREPARED_STATEMENT, id, debugCodeAssign("PreparedStatement", TraceObject.PREPARED_STATEMENT, id,
"prepareStatement(" + quote(sql) + ", " + resultSetType + ", " + resultSetConcurrency + ", " "prepareStatement(" + quote(sql) + ", " + resultSetType + ", " + resultSetConcurrency + ", "
+ resultSetHoldability + ")"); + resultSetHoldability + ")");
} }
...@@ -881,7 +881,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -881,7 +881,7 @@ public class JdbcConnection extends TraceObject implements Connection {
/** /**
* Creates a new prepared statement. This method just calls * Creates a new prepared statement. This method just calls
* prepareStatement(String sql). * prepareStatement(String sql).
* *
* @return the prepared statement * @return the prepared statement
* @throws SQLException * @throws SQLException
* if the connection is closed * if the connection is closed
...@@ -909,7 +909,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -909,7 +909,7 @@ public class JdbcConnection extends TraceObject implements Connection {
if (ci.isRemote()) { if (ci.isRemote()) {
session = new SessionRemote().createSession(ci); session = new SessionRemote().createSession(ci);
} else { } else {
SessionInterface si = (SessionInterface) ClassUtils.loadClass("org.h2.engine.Session").newInstance(); SessionInterface si = (SessionInterface) ClassUtils.loadSystemClass("org.h2.engine.Session").newInstance();
String baseDir = SysProperties.getBaseDir(); String baseDir = SysProperties.getBaseDir();
if (baseDir != null) { if (baseDir != null) {
ci.setBaseDir(baseDir); ci.setBaseDir(baseDir);
...@@ -921,7 +921,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -921,7 +921,7 @@ public class JdbcConnection extends TraceObject implements Connection {
setTrace(trace, TraceObject.CONNECTION, id); setTrace(trace, TraceObject.CONNECTION, id);
this.user = ci.getUserName(); this.user = ci.getUserName();
if (info()) { if (info()) {
trace.infoCode("Connection " + getTraceObjectName() trace.infoCode("Connection " + getTraceObjectName()
+ " = DriverManager.getConnection(" + quote(url) + " = DriverManager.getConnection(" + quote(url)
+ ", " + quote(user) + ", \"\")"); + ", " + quote(user) + ", \"\")");
} }
...@@ -964,7 +964,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -964,7 +964,7 @@ public class JdbcConnection extends TraceObject implements Connection {
CommandInterface prepareCommand(String sql, CommandInterface old) throws SQLException { CommandInterface prepareCommand(String sql, CommandInterface old) throws SQLException {
return old == null ? session.prepareCommand(sql) : old; return old == null ? session.prepareCommand(sql) : old;
} }
private int translateGetEnd(String sql, int i, char c) throws SQLException { private int translateGetEnd(String sql, int i, char c) throws SQLException {
int len = sql.length(); int len = sql.length();
switch(c) { switch(c) {
...@@ -1224,7 +1224,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -1224,7 +1224,7 @@ public class JdbcConnection extends TraceObject implements Connection {
getGeneratedKeys = prepareCommand("CALL IDENTITY()", getGeneratedKeys); getGeneratedKeys = prepareCommand("CALL IDENTITY()", getGeneratedKeys);
return getGeneratedKeys.executeQuery(0, false); return getGeneratedKeys.executeQuery(0, false);
} }
/** /**
* Create a new empty Clob object. * Create a new empty Clob object.
* *
...@@ -1290,7 +1290,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -1290,7 +1290,7 @@ public class JdbcConnection extends TraceObject implements Connection {
} }
*/ */
//#endif //#endif
/** /**
* [Not supported] Create a new empty Array object. * [Not supported] Create a new empty Array object.
*/ */
...@@ -1301,15 +1301,15 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -1301,15 +1301,15 @@ public class JdbcConnection extends TraceObject implements Connection {
} }
*/ */
//#endif //#endif
/** /**
* [Not supported] Create a new empty Struct object. * [Not supported] Create a new empty Struct object.
*/ */
//#ifdef JDK16 //#ifdef JDK16
/* /*
public Struct createStruct(String typeName, Object[] attributes) throws SQLException { public Struct createStruct(String typeName, Object[] attributes) throws SQLException {
throw Message.getUnsupportedException(); throw Message.getUnsupportedException();
} }
*/ */
//#endif //#endif
...@@ -1334,7 +1334,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -1334,7 +1334,7 @@ public class JdbcConnection extends TraceObject implements Connection {
/** /**
* [Not supported] Set a client property. * [Not supported] Set a client property.
*/ */
//#ifdef JDK16 //#ifdef JDK16
/* /*
public void setClientInfo(String name, String value) throws SQLClientInfoException { public void setClientInfo(String name, String value) throws SQLClientInfoException {
throw new SQLClientInfoException(); throw new SQLClientInfoException();
...@@ -1352,7 +1352,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -1352,7 +1352,7 @@ public class JdbcConnection extends TraceObject implements Connection {
} }
*/ */
//#endif //#endif
/** /**
* [Not supported] Get the client properties. * [Not supported] Get the client properties.
*/ */
...@@ -1362,7 +1362,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -1362,7 +1362,7 @@ public class JdbcConnection extends TraceObject implements Connection {
throw new SQLClientInfoException(); throw new SQLClientInfoException();
} }
*/ */
//#endif //#endif
/** /**
* [Not supported] Set a client property. * [Not supported] Set a client property.
...@@ -1392,7 +1392,7 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -1392,7 +1392,7 @@ public class JdbcConnection extends TraceObject implements Connection {
} }
*/ */
//#endif //#endif
Value createClob(Reader x, long length) throws SQLException { Value createClob(Reader x, long length) throws SQLException {
if (x == null) { if (x == null) {
return ValueNull.INSTANCE; return ValueNull.INSTANCE;
...@@ -1414,18 +1414,18 @@ public class JdbcConnection extends TraceObject implements Connection { ...@@ -1414,18 +1414,18 @@ public class JdbcConnection extends TraceObject implements Connection {
Value v = ValueLob.createBlob(x, length, session.getDataHandler()); Value v = ValueLob.createBlob(x, length, session.getDataHandler());
return v; return v;
} }
private void checkMap(Map map) throws SQLException { private void checkMap(Map map) throws SQLException {
if (map != null && map.size() > 0) { if (map != null && map.size() > 0) {
throw Message.getUnsupportedException(); throw Message.getUnsupportedException();
} }
} }
/** /**
* INTERNAL * INTERNAL
*/ */
public String toString() { public String toString() {
return getTraceObjectName() + ": url=" + url + " user=" + user; return getTraceObjectName() + ": url=" + url + " user=" + user;
} }
} }
...@@ -153,7 +153,8 @@ ...@@ -153,7 +153,8 @@
90130=Diese Methode ist nicht erlaubt f\u00FCr ein PreparedStatement; ben\u00FCtzen Sie ein Statement. 90130=Diese Methode ist nicht erlaubt f\u00FCr ein PreparedStatement; ben\u00FCtzen Sie ein Statement.
90131=Gleichzeitige \u00C4nderung in Tabelle {0}\: eine andere Transaktion hat den gleichen Datensatz ge\u00E4ndert oder gel\u00F6scht 90131=Gleichzeitige \u00C4nderung in Tabelle {0}\: eine andere Transaktion hat den gleichen Datensatz ge\u00E4ndert oder gel\u00F6scht
90132=Aggregat-Funktion {0} nicht gefunden 90132=Aggregat-Funktion {0} nicht gefunden
90133=\#Cannot change the setting {0} when the database is already open 90133=Kann das Setting {0} nicht \u00E4ndern wenn die Datenbank bereits ge\u00F6ffnet ist
90134=Der Zugriff auf die Klasse {0} ist nicht erlaubt
HY000=Allgemeiner Fehler\: {0} HY000=Allgemeiner Fehler\: {0}
HY004=Unbekannter Datentyp\: {0} HY004=Unbekannter Datentyp\: {0}
HYC00=Dieses Feature wird unterst\u00FCtzt HYC00=Dieses Feature wird unterst\u00FCtzt
......
...@@ -154,6 +154,7 @@ ...@@ -154,6 +154,7 @@
90131=Concurrent update in table {0}\: another transaction has updated or deleted the same row 90131=Concurrent update in table {0}\: another transaction has updated or deleted the same row
90132=Aggregate {0} not found 90132=Aggregate {0} not found
90133=Cannot change the setting {0} when the database is already open 90133=Cannot change the setting {0} when the database is already open
90134=Access to the class {0} is denied
HY000=General error\: {0} HY000=General error\: {0}
HY004=Unknown data type\: {0} HY004=Unknown data type\: {0}
HYC00=Feature not supported HYC00=Feature not supported
......
...@@ -154,6 +154,7 @@ ...@@ -154,6 +154,7 @@
90131=\u30C6\u30FC\u30D6\u30EB {0} \u306B\u4E26\u884C\u3057\u3066\u66F4\u65B0\u304C\u884C\u308F\u308C\u307E\u3057\u305F\: \u5225\u306E\u30C8\u30E9\u30F3\u30B6\u30AF\u30B7\u30E7\u30F3\u304C\u3001\u540C\u3058\u884C\u306B\u66F4\u65B0\u304B\u524A\u9664\u3092\u884C\u3044\u307E\u3057\u305F 90131=\u30C6\u30FC\u30D6\u30EB {0} \u306B\u4E26\u884C\u3057\u3066\u66F4\u65B0\u304C\u884C\u308F\u308C\u307E\u3057\u305F\: \u5225\u306E\u30C8\u30E9\u30F3\u30B6\u30AF\u30B7\u30E7\u30F3\u304C\u3001\u540C\u3058\u884C\u306B\u66F4\u65B0\u304B\u524A\u9664\u3092\u884C\u3044\u307E\u3057\u305F
90132=\#Aggregate {0} not found 90132=\#Aggregate {0} not found
90133=\#Cannot change the setting {0} when the database is already open 90133=\#Cannot change the setting {0} when the database is already open
90134=\#Access to the class {0} is denied
HY000=\u4E00\u822C\u30A8\u30E9\u30FC\: {0} HY000=\u4E00\u822C\u30A8\u30E9\u30FC\: {0}
HY004=\u4E0D\u660E\u306A\u30C7\u30FC\u30BF\u578B\: {0} HY004=\u4E0D\u660E\u306A\u30C7\u30FC\u30BF\u578B\: {0}
HYC00=\u6A5F\u80FD\u306F\u30B5\u30DD\u30FC\u30C8\u3055\u308C\u3066\u3044\u307E\u305B\u3093 HYC00=\u6A5F\u80FD\u306F\u30B5\u30DD\u30FC\u30C8\u3055\u308C\u3066\u3044\u307E\u305B\u3093
......
...@@ -154,6 +154,7 @@ ...@@ -154,6 +154,7 @@
90131=\#Concurrent update in table {0}\: another transaction has updated or deleted the same row 90131=\#Concurrent update in table {0}\: another transaction has updated or deleted the same row
90132=\#Aggregate {0} not found 90132=\#Aggregate {0} not found
90133=\#Cannot change the setting {0} when the database is already open 90133=\#Cannot change the setting {0} when the database is already open
90134=\#Access to the class {0} is denied
HY000=Blad ogolny\: {0} HY000=Blad ogolny\: {0}
HY004=Nieznany typ danyche\: {0} HY004=Nieznany typ danyche\: {0}
HYC00=Cecha nie jest wspierana HYC00=Cecha nie jest wspierana
......
...@@ -154,6 +154,7 @@ ...@@ -154,6 +154,7 @@
90131=Atualiza\u00E7\u00E3o concorrente na tabela {0}\: outra transa\u00E7\u00E3o atualizou ou deletou a mesma linha 90131=Atualiza\u00E7\u00E3o concorrente na tabela {0}\: outra transa\u00E7\u00E3o atualizou ou deletou a mesma linha
90132=Agrega\u00E7\u00E3o {0} n\u00E3o encontrada 90132=Agrega\u00E7\u00E3o {0} n\u00E3o encontrada
90133=\#Cannot change the setting {0} when the database is already open 90133=\#Cannot change the setting {0} when the database is already open
90134=\#Access to the class {0} is denied
HY000=Erro geral\: {0} HY000=Erro geral\: {0}
HY004=Tipo de dados desconhecido\: {0} HY004=Tipo de dados desconhecido\: {0}
HYC00=Recurso n\u00E3o suportado HYC00=Recurso n\u00E3o suportado
......
...@@ -52,7 +52,7 @@ public class TriggerObject extends SchemaObjectBase { ...@@ -52,7 +52,7 @@ public class TriggerObject extends SchemaObjectBase {
this.triggerClassName = triggerClassName; this.triggerClassName = triggerClassName;
try { try {
Connection c2 = session.createConnection(false); Connection c2 = session.createConnection(false);
Object obj = session.getDatabase().loadClass(triggerClassName).newInstance(); Object obj = session.getDatabase().loadUserClass(triggerClassName).newInstance();
triggerCallback = (Trigger) obj; triggerCallback = (Trigger) obj;
triggerCallback.init(c2, getSchema().getName(), getName(), table.getName()); triggerCallback.init(c2, getSchema().getName(), getName(), table.getName());
} catch (Throwable e) { } catch (Throwable e) {
......
...@@ -39,9 +39,9 @@ import org.h2.util.Resources; ...@@ -39,9 +39,9 @@ import org.h2.util.Resources;
import org.h2.util.SortedProperties; import org.h2.util.SortedProperties;
public class WebServer implements Service { public class WebServer implements Service {
private static final String DEFAULT_LANGUAGE = "en"; private static final String DEFAULT_LANGUAGE = "en";
private static final String[][] LANGUAGES = { private static final String[][] LANGUAGES = {
{ "de", "Deutsch" }, { "de", "Deutsch" },
{ "en", "English" }, { "en", "English" },
...@@ -55,10 +55,11 @@ public class WebServer implements Service { ...@@ -55,10 +55,11 @@ public class WebServer implements Service {
{ "pt_BR", "Portugu\u00eas (Brasil)"}, { "pt_BR", "Portugu\u00eas (Brasil)"},
{ "pt_PT", "Portugu\u00eas (Europeu)"}, { "pt_PT", "Portugu\u00eas (Europeu)"},
{ "ru", "\u0440\u0443\u0441\u0441\u043a\u0438\u0439"}, { "ru", "\u0440\u0443\u0441\u0441\u043a\u0438\u0439"},
{ "tr", "T\u00fcrk\u00e7e"},
{ "uk", "\u0423\u043A\u0440\u0430\u0457\u043D\u0441\u044C\u043A\u0430"}, { "uk", "\u0423\u043A\u0440\u0430\u0457\u043D\u0441\u044C\u043A\u0430"},
{ "zh_CN", "\u4E2D\u6587"}, { "zh_CN", "\u4E2D\u6587"},
}; };
private static final String[] GENERIC = new String[] { private static final String[] GENERIC = new String[] {
"Generic JNDI Data Source|javax.naming.InitialContext|java:comp/env/jdbc/Test|sa", "Generic JNDI Data Source|javax.naming.InitialContext|java:comp/env/jdbc/Test|sa",
"Generic Firebird Server|org.firebirdsql.jdbc.FBDriver|jdbc:firebirdsql:localhost:c:/temp/firebird/test|sysdba", "Generic Firebird Server|org.firebirdsql.jdbc.FBDriver|jdbc:firebirdsql:localhost:c:/temp/firebird/test|sysdba",
...@@ -83,13 +84,13 @@ public class WebServer implements Service { ...@@ -83,13 +84,13 @@ public class WebServer implements Service {
java.util.Locale.CHINESE.getDisplayLanguage( java.util.Locale.CHINESE.getDisplayLanguage(
java.util.Locale.CHINESE); java.util.Locale.CHINESE);
for(int i=0; i<lang.length(); i++) for(int i=0; i<lang.length(); i++)
System.out.println(Integer.toHexString(lang.charAt(i))+" "); System.out.println(Integer.toHexString(lang.charAt(i))+" ");
*/ */
/** /**
* Hungarian spec chars: &eacute;&#369;&aacute;&#337;&uacute;&ouml;&uuml;&oacute;&iacute;&Eacute;&Aacute;&#368;&#336;&Uacute;&Ouml;&Uuml;&Oacute;&Iacute; * Hungarian spec chars: &eacute;&#369;&aacute;&#337;&uacute;&ouml;&uuml;&oacute;&iacute;&Eacute;&Aacute;&#368;&#336;&Uacute;&Ouml;&Uuml;&Oacute;&Iacute;
* Or use PropertiesToUTF8 * Or use PropertiesToUTF8
*/ */
// private URLClassLoader urlClassLoader; // private URLClassLoader urlClassLoader;
private String driverList; private String driverList;
private static int ticker; private static int ticker;
...@@ -98,7 +99,7 @@ public class WebServer implements Service { ...@@ -98,7 +99,7 @@ public class WebServer implements Service {
private Set running = Collections.synchronizedSet(new HashSet()); private Set running = Collections.synchronizedSet(new HashSet());
private boolean ssl; private boolean ssl;
private HashMap connInfoMap = new HashMap(); private HashMap connInfoMap = new HashMap();
private static final long SESSION_TIMEOUT = 30 * 60 * 1000; // timeout is 30 min private static final long SESSION_TIMEOUT = 30 * 60 * 1000; // timeout is 30 min
private long lastTimeoutCheck; private long lastTimeoutCheck;
private HashMap sessions = new HashMap(); private HashMap sessions = new HashMap();
...@@ -125,10 +126,10 @@ public class WebServer implements Service { ...@@ -125,10 +126,10 @@ public class WebServer implements Service {
byte[] bytes = getFile(file); byte[] bytes = getFile(file);
return new String(bytes); return new String(bytes);
} }
synchronized void remove(WebThread t) { synchronized void remove(WebThread t) {
running.remove(t); running.remove(t);
} }
private String generateSessionId() { private String generateSessionId() {
byte[] buff = RandomUtils.getSecureBytes(16); byte[] buff = RandomUtils.getSecureBytes(16);
...@@ -278,7 +279,7 @@ public class WebServer implements Service { ...@@ -278,7 +279,7 @@ public class WebServer implements Service {
Statement stat = session.executingStatement; Statement stat = session.executingStatement;
if (stat != null) { if (stat != null) {
try { try {
stat.cancel(); stat.cancel();
} catch (Exception e) { } catch (Exception e) {
// ignore // ignore
} }
...@@ -300,11 +301,11 @@ public class WebServer implements Service { ...@@ -300,11 +301,11 @@ public class WebServer implements Service {
void trace(String s) { void trace(String s) {
// System.out.println(s); // System.out.println(s);
} }
public void traceError(Exception e) { public void traceError(Exception e) {
e.printStackTrace(); e.printStackTrace();
} }
public boolean supportsLanguage(String language) { public boolean supportsLanguage(String language) {
return languages.contains(language); return languages.contains(language);
} }
...@@ -479,7 +480,7 @@ public class WebServer implements Service { ...@@ -479,7 +480,7 @@ public class WebServer implements Service {
url += ";IFEXISTS=TRUE"; url += ";IFEXISTS=TRUE";
} }
p.put("DATABASE_EVENT_LISTENER_OBJECT", listener); p.put("DATABASE_EVENT_LISTENER_OBJECT", listener);
// PostgreSQL would throw a NullPointerException // PostgreSQL would throw a NullPointerException
// if it is loaded before the H2 driver // if it is loaded before the H2 driver
// because it can't deal with non-String objects in the connection Properties // because it can't deal with non-String objects in the connection Properties
return org.h2.Driver.load().connect(url, p); return org.h2.Driver.load().connect(url, p);
......
.translator=R&\#305;dvan A&\#287;ar
a.help=Yard&\#305;m
a.language=T&\#252;rk&\#231;e
a.lynxNotSupported=Web taray&\#305;c&\#305;n&\#305;z HTML Frames'i desteklemiyor. Frames (ve Javascript) deste&\#287;i gerekli.
a.password=&\#350;ifre
a.remoteConnectionsDisabled=Ba&\#351;ka bilgisayarlardan, veri taban&\#305;na ba&\#287;lanma izni hen&\#252;z ayarlanmam&\#305;&\#351; ('webAllowOthers').
a.title=H2 Konsolu
a.user=Kullan&\#305;c&\#305; ad&\#305;
admin.executing=Aktif
admin.ip=IP
admin.lastAccess=Son ba&\#287;lant&\#305;
admin.lastQuery=Son komut
admin.url=URL
adminAllow=&\#304;zin verilen ba&\#287;lant&\#305;lar
adminConnection=Ba&\#287;lant&\#305; g&\#252;venli&\#287;i
adminHttp=&\#350;ifrelenmemi&\#351; HTTP ba&\#287;lant&\#305;lar&\#305;
adminHttps=&\#350;ifrelenmi&\#351; HTTP ba&\#287;lant&\#305;lar&\#305;
adminLocal=Sadece yerel ba&\#287;lant&\#305;lara izin ver
adminLogin=Y&\#246;netim giri&\#351;i
adminLoginCancel=&\#304;ptal et
adminLoginOk=Tamam
adminLogout=Bitir
adminOthers=Ba&\#351;ka bilgisayarlardan, veri taban&\#305;na ba&\#287;lanma izni ver
adminPort=Port
adminPortWeb=Web-Server Port
adminRestart=De&\#287;i&\#351;iklikler veri taban&\#305; hizmet&\#231;isinin yeniden ba&\#351;lat&\#305;lmas&\#305;yla etkinlik kazanacak.
adminSave=Kaydet
adminSessions=Aktif ba&\#287;lant&\#305;lar
adminShutdown=Kapat
adminTitle=H2 Konsol ayarlar&\#305;
helpAction=Aksiyon
helpAddAnotherRow=Yeni bir sat&\#305;r ekle
helpAddDrivers=Veritaban&\#305; s&\#252;r&\#252;c&\#252;s&\#252; ekle
helpAddDriversOnlyJava=Ek s&\#252;r&\#252;c&\#252;ler sadece Java s&\#252;r&\#252;m&\#252; ile kullan&\#305;labilir.
helpAddDriversText=Yeni veri taban&\#305; s&\#252;r&\#252;c&\#252;leri eklemek i&\#231;in, s&\#252;r&\#252;c&\#252; dosyalar&\#305;n&\#305;n yerini H2DRIVERS yada CLASSPATH &\#231;evre de&\#287;i&\#351;kenlerine ekleyebilirsiniz. &\#214;rnek (Windows)\: S&\#252;r&\#252;c&\#252; dosyas&\#305; C\:\\Programs\\hsqldb\\lib\\hsqldb.jar ise H2DRIVERS de&\#287;i&\#351;kenini C\:\\Programs\\hsqldb\\lib\\hsqldb.jar olarak girin.
helpAddRow=Veri taban&\#305;na yeni bir sat&\#305;r ekler
helpCommandHistory=Komut tarih&\#231;esini g&\#246;sterir
helpCreateTable=Veri taban&\#305;na yeni bir tabela ekler
helpDeleteRow=Tabeladan sat&\#305;r&\#305; siler
helpDisconnect=Veri taban&\#305; ba&\#287;lant&\#305;s&\#305;n&\#305; keser
helpDisplayThis=Bu yard&\#305;m sayfas&\#305;n&\#305; g&\#246;sterir
helpDropTable=Var ise, istenen tabelay&\#305; siler
helpExecuteCurrent=Girilen SQL komutunu icra eder
helpIcon=&\#350;alter
helpImportantCommands=&\#214;nemli komutlar
helpOperations=&\#304;&\#351;lemler
helpQuery=Tabela i&\#231;eri&\#287;ini g&\#246;sterir
helpSampleSQL=&\#214;rnek SQL
helpStatements=SQL komutlar&\#305;
helpUpdate=Bir tabeladaki belli bir sat&\#305;r i&\#231;eri&\#287;ini de&\#287;i&\#351;tirir
helpWithColumnsIdName=Colon isimleriyle birlikte
login.connect=Ba&\#287;lan
login.driverClass=Veri taban&\#305; s&\#252;r&\#252;c&\#252; s&\#305;n&\#305;f&\#305;
login.driverNotFound=&\#304;stenilen veri taban&\#305; s&\#252;r&\#252;c&\#252;s&\#252; bulunamad&\#305;<br />S&\#252;r&\#252;c&\#252; ekleme konusunda bilgi i&\#231;in Yard&\#305;m'a ba&\#351;vurunuz
login.goAdmin=Se&\#231;enekler
login.jdbcUrl=JDBC URL
login.language=Dil
login.login=Gir
login.remove=Sil
login.save=Kaydet
login.savedSetting=Kay&\#305;tl&\#305; ayarlar
login.settingName=Ayar ad&\#305;
login.testConnection=Ba&\#287;lant&\#305;y&\#305; test et
login.testSuccessful=Test ba&\#351;ar&\#305;l&\#305;
login.welcome=H2 Konsolu
result.1row=1 dizi
result.autoCommitOff=Auto-Commit kapat&\#305;ld&\#305;
result.autoCommitOn=Auto-Commit a&\#231;&\#305;ld&\#305;
result.maxrowsSet=Maximum dizi say&\#305;s&\#305; ayar&\#305; yap&\#305;ld&\#305;
result.noRows=Hi&\#231; bir bilgi yok
result.noRunningStatement=&\#350;u an bir komut icra ediliyor
result.rows=Dizi
result.statementWasCancelled=Komut iptal edildi
result.updateCount=G&\#252;ncelle&\#351;terilen dizi say&\#305;s&\#305;
resultEdit.add=Ekle
resultEdit.cancel=&\#304;ptal
resultEdit.delete=Sil
resultEdit.edit=De&\#287;i&\#351;tir
resultEdit.editResult=De&\#287;i&\#351;tir
resultEdit.save=Kaydet
toolbar.all=Hepsi
toolbar.autoCommit=Auto-Commit
toolbar.autoComplete=Auto-Complete
toolbar.autoComplete.full=Hepsi
toolbar.autoComplete.normal=Normal
toolbar.autoComplete.off=Kapal&\#305;
toolbar.cancelStatement=Y&\#252;r&\#252;t&\#252;len i&\#351;lemi iptal et
toolbar.clear=Temizle
toolbar.commit=Degi&\#351;iklikleri kaydet
toolbar.disconnect=Ba&\#287;lant&\#305;y&\#305; kes
toolbar.history=Verilmi&\#351; olan komutlar
toolbar.maxRows=Maximum dizi say&\#305;s&\#305;
toolbar.refresh=G&\#252;ncelle&\#351;tir
toolbar.rollback=De&\#287;i&\#351;iklikleri geri al
toolbar.run=&\#304;&\#351;lemi y&\#252;r&\#252;t
toolbar.sqlStatement=SQL komutu
tree.admin=Y&\#246;netici
tree.current=G&\#252;ncel de&\#287;er
tree.hashed=Hash tabanl&\#305;
tree.increment=Art&\#305;r
tree.indexes=Indexler
tree.nonUnique=e&\#351;siz de&\#287;il
tree.sequences=Dizinler
tree.unique=E&\#351;siz
tree.users=Kullan&\#305;c&\#305;
...@@ -1172,7 +1172,7 @@ public class MetaTable extends Table { ...@@ -1172,7 +1172,7 @@ public class MetaTable extends Table {
"" + trigger.getQueueSize(), // QUEUE_SIZE INT "" + trigger.getQueueSize(), // QUEUE_SIZE INT
"" + trigger.getNoWait(), // NO_WAIT BIT "" + trigger.getNoWait(), // NO_WAIT BIT
replaceNullWithEmpty(trigger.getComment()), // REMARKS replaceNullWithEmpty(trigger.getComment()), // REMARKS
trigger.getSQL(), // SQL trigger.getCreateSQL(), // SQL
"" + trigger.getId() // ID "" + trigger.getId() // ID
}); });
} }
......
...@@ -28,9 +28,9 @@ import org.h2.util.StringUtils; ...@@ -28,9 +28,9 @@ import org.h2.util.StringUtils;
/** /**
* Executes the contents of a SQL script file against a database. * Executes the contents of a SQL script file against a database.
* *
* @author Tom * @author Tom
* *
*/ */
public class RunScript { public class RunScript {
...@@ -39,7 +39,7 @@ public class RunScript { ...@@ -39,7 +39,7 @@ public class RunScript {
} }
/** /**
* The command line interface for this tool. The options must be split into strings like this: "-user", "sa",... * The command line interface for this tool. The options must be split into strings like this: "-user", "sa",...
* Options are case sensitive. The following options are supported: * Options are case sensitive. The following options are supported:
* <ul> * <ul>
* <li>-help or -? (print the list of options) * <li>-help or -? (print the list of options)
...@@ -54,9 +54,9 @@ public class RunScript { ...@@ -54,9 +54,9 @@ public class RunScript {
* <pre> * <pre>
* &#64;INCLUDE fileName * &#64;INCLUDE fileName
* </pre> * </pre>
* This syntax is only supported by this tool. * This syntax is only supported by this tool.
* Embedded RUNSCRIPT SQL statements will be executed by the database. * Embedded RUNSCRIPT SQL statements will be executed by the database.
* *
* @param args the command line arguments * @param args the command line arguments
* @throws SQLException * @throws SQLException
*/ */
...@@ -88,7 +88,7 @@ public class RunScript { ...@@ -88,7 +88,7 @@ public class RunScript {
} else if (args[i].equals("-driver")) { } else if (args[i].equals("-driver")) {
String driver = args[++i]; String driver = args[++i];
try { try {
ClassUtils.loadClass(driver); ClassUtils.loadUserClass(driver);
} catch (ClassNotFoundException e) { } catch (ClassNotFoundException e) {
throw Message.convert(e); throw Message.convert(e);
} }
...@@ -126,7 +126,7 @@ public class RunScript { ...@@ -126,7 +126,7 @@ public class RunScript {
/** /**
* Executes the SQL commands in a script file against a database. * Executes the SQL commands in a script file against a database.
* *
* @param conn the connection to a database * @param conn the connection to a database
* @param reader the reader * @param reader the reader
* @return the last result set * @return the last result set
...@@ -213,7 +213,7 @@ public class RunScript { ...@@ -213,7 +213,7 @@ public class RunScript {
/** /**
* Executes the SQL commands in a script file against a database. * Executes the SQL commands in a script file against a database.
* *
* @param url the database URL * @param url the database URL
* @param user the user name * @param user the user name
* @param password the password * @param password the password
......
...@@ -4,10 +4,57 @@ ...@@ -4,10 +4,57 @@
*/ */
package org.h2.util; package org.h2.util;
import java.sql.SQLException;
import java.util.ArrayList;
import java.util.HashSet;
import org.h2.constant.ErrorCode;
import org.h2.constant.SysProperties;
import org.h2.message.Message;
public class ClassUtils { public class ClassUtils {
public static Class loadClass(String className) throws ClassNotFoundException { private static final boolean ALLOW_ALL;
// TODO support special syntax to load classes using another classloader private static final HashSet ALLOWED_CLASS_NAMES = new HashSet();
private static final String[] ALLOWED_CLASS_NAME_PREFIXES;
static {
String s = SysProperties.ALLOWED_CLASSES;
String[] list = StringUtils.arraySplit(s, ',', true);
ArrayList prefixes = new ArrayList();
boolean allowAll = false;
for (int i = 0; i < list.length; i++) {
String p = list[i];
if (p.equals("*")) {
allowAll = true;
} else if (p.endsWith("*")) {
prefixes.add(p.substring(0, p.length() - 1));
} else {
ALLOWED_CLASS_NAMES.add(p);
}
}
ALLOW_ALL = allowAll;
ALLOWED_CLASS_NAME_PREFIXES = new String[prefixes.size()];
prefixes.toArray(ALLOWED_CLASS_NAME_PREFIXES);
}
public static Class loadSystemClass(String className) throws ClassNotFoundException {
return Class.forName(className);
}
public static Class loadUserClass(String className) throws ClassNotFoundException, SQLException {
if (!ALLOW_ALL && !ALLOWED_CLASS_NAMES.contains(className)) {
boolean allowed = false;
for (int i = 0; i < ALLOWED_CLASS_NAME_PREFIXES.length; i++) {
String s = ALLOWED_CLASS_NAME_PREFIXES[i];
if (className.startsWith(s)) {
allowed = true;
}
}
if (!allowed) {
throw Message.getSQLException(ErrorCode.ACCESS_DENIED_TO_CLASS_1, className);
}
}
return Class.forName(className); return Class.forName(className);
} }
......
/* /*
* Copyright 2004-2007 H2 Group. Licensed under the H2 License, Version 1.0 (http://h2database.com/html/license.html). * Copyright 2004-2007 H2 Group. Licensed under the H2 License, Version 1.0 (http://h2database.com/html/license.html).
* Initial Developer: H2 Group * Initial Developer: H2 Group
*/ */
package org.h2.util; package org.h2.util;
...@@ -22,7 +22,7 @@ import org.h2.constant.ErrorCode; ...@@ -22,7 +22,7 @@ import org.h2.constant.ErrorCode;
import org.h2.message.Message; import org.h2.message.Message;
public class JdbcUtils { public class JdbcUtils {
public static void closeSilently(Statement stat) { public static void closeSilently(Statement stat) {
if (stat != null) { if (stat != null) {
try { try {
...@@ -52,7 +52,7 @@ public class JdbcUtils { ...@@ -52,7 +52,7 @@ public class JdbcUtils {
} }
} }
} }
public static ResultSet getGeneratedKeys(Statement stat) throws SQLException { public static ResultSet getGeneratedKeys(Statement stat) throws SQLException {
ResultSet rs = null; ResultSet rs = null;
//#ifdef JDK14 //#ifdef JDK14
...@@ -79,11 +79,11 @@ public class JdbcUtils { ...@@ -79,11 +79,11 @@ public class JdbcUtils {
prop.setProperty("password", password); prop.setProperty("password", password);
return getConnection(driver, url, prop); return getConnection(driver, url, prop);
} }
public static Connection getConnection(String driver, String url, Properties prop) throws SQLException { public static Connection getConnection(String driver, String url, Properties prop) throws SQLException {
if (!StringUtils.isNullOrEmpty(driver)) { if (!StringUtils.isNullOrEmpty(driver)) {
try { try {
Class d = ClassUtils.loadClass(driver); Class d = ClassUtils.loadUserClass(driver);
if (java.sql.Driver.class.isAssignableFrom(d)) { if (java.sql.Driver.class.isAssignableFrom(d)) {
return DriverManager.getConnection(url, prop); return DriverManager.getConnection(url, prop);
//#ifdef JDK14 //#ifdef JDK14
...@@ -106,7 +106,7 @@ public class JdbcUtils { ...@@ -106,7 +106,7 @@ public class JdbcUtils {
} else { } else {
// Don't know, but maybe it loaded a JDBC Driver // Don't know, but maybe it loaded a JDBC Driver
return DriverManager.getConnection(url, prop); return DriverManager.getConnection(url, prop);
} }
} catch (ClassNotFoundException e) { } catch (ClassNotFoundException e) {
throw Message.getSQLException(ErrorCode.CLASS_NOT_FOUND_1, new String[]{driver}, e); throw Message.getSQLException(ErrorCode.CLASS_NOT_FOUND_1, new String[]{driver}, e);
} }
......
...@@ -156,22 +156,6 @@ C:\temp\test\db ...@@ -156,22 +156,6 @@ C:\temp\test\db
No more No more
@author @author
SQL column in INFORMATION_SCHEMA.TRIGGERS
build.xml
org/h2/server/web/*.*
They are currently in the tools folder, I will move them to the main folder.
Add unit tests.
History:
The classes DbStarter and WebServlet have been moved to src/main.
Improved debugging support: toString methods of most object now return a meaningful text.
This database could not be used in applets. Fixed
A stack trace was thrown if the system did not provide a quick secure
random source and if there is no network or the network settings are not configured. Fixed.
toString: > the parameters for the prepared statements.
autocomplete only just after meaningful key (ctrl+space, space, bs, ...) autocomplete only just after meaningful key (ctrl+space, space, bs, ...)
write more tests for the command line tools write more tests for the command line tools
......
...@@ -443,17 +443,17 @@ unavailable repeating sponsored indonesian yuliantoro joko indonesia unlike ...@@ -443,17 +443,17 @@ unavailable repeating sponsored indonesian yuliantoro joko indonesia unlike
truncating ronni ptn avalon nielsen hammant picked sequoia continuent deebee paul truncating ronni ptn avalon nielsen hammant picked sequoia continuent deebee paul
lister testa testb tar von lister testa testb tar von
amazing timer allowing programmers pictures scramble portal bots tempted legacy amazing timer allowing programmers pictures scramble portal bots tempted legacy
semicolons luckily involving die prevalent manipulating risks unmapped solutions semicolons luckily involving die prevalent manipulating risks unmapped solutions
preventing prevented retry superfluous varying tend revolutions emit technically preventing prevented retry superfluous varying tend revolutions emit technically
excessive among lazy synchronous technique patented ability cycle difficult rejects excessive among lazy synchronous technique patented ability cycle difficult rejects
animal achieves touch produced smallest vulnerabilities descriptive verify thinks animal achieves touch produced smallest vulnerabilities descriptive verify thinks
potential lose novel handy filtering wonder story cool prevents animals wrote potential lose novel handy filtering wonder story cool prevents animals wrote
tier seen young providing extreme images apple rpm thousand compromise tier seen young providing extreme images apple rpm thousand compromise
sandbox greatest whatever placeholder creative leak hacker benefits station sandbox greatest whatever placeholder creative leak hacker benefits station
million prevention stuck titles fiche blogs showed widespread cut placeholders million prevention stuck titles fiche blogs showed widespread cut placeholders
graph prohibit confusing clever automated nutshell scriptella etl tamava semmle graph prohibit confusing clever automated nutshell scriptella etl tamava semmle
googlegroups guidewire thecodist captcha brewster semmle ddlutils analyse dave googlegroups guidewire thecodist captcha brewster semmle ddlutils analyse dave
maxvalue samooha dbrewster minvalue darwin follow graphics typically maxvalue samooha dbrewster minvalue darwin follow graphics typically
netscape mywebpage javaplayer fuse davidlbarron helps player appfuse awt netscape mywebpage javaplayer fuse davidlbarron helps player appfuse awt
gridwidth editable pressed entered awt east toolkit insets exited grid mouse west resizable popup focusable bag anchor gridwidth editable pressed entered awt east toolkit insets exited grid mouse west resizable popup focusable bag anchor
...@@ -465,34 +465,34 @@ initializers crashes openoffice member forgotten ...@@ -465,34 +465,34 @@ initializers crashes openoffice member forgotten
oldest fat oldest fat
### check those again: ### check those again:
populate slowly xacon inser maxbqualsize counter regards attaching official xatest populate slowly xacon inser maxbqualsize counter regards attaching official xatest
xids rmerr xadb rdonly occured maxgtridsize bordea con patches suffixer risky xids rmerr xadb rdonly occured maxgtridsize bordea con patches suffixer risky
portuguese parameterized interpret construct maximus seem solo portugu tds portuguese parameterized interpret construct maximus seem solo portugu tds
symmetrical printed syb conversions doe ntfs insertquery interested come man symmetrical printed syb conversions doe ntfs insertquery interested come man
blobtest overload hen datetimes stolen firstly fild mission europe instruct instantiated blobtest overload hen datetimes stolen firstly fild mission europe instruct instantiated
recid selectquery msg japan portugal atlas dbsolo henplus soft equivalent watch recid selectquery msg japan portugal atlas dbsolo henplus soft equivalent watch
createquery securing unambiguously presume umambiguously realised printing createquery securing unambiguously presume umambiguously realised printing
comulative largely perhaps inputting restores observation oversight actuality behaviours comulative largely perhaps inputting restores observation oversight actuality behaviours
isn truly toptier older meant pavel byteblob benchmarking regarding great unqualified isn truly toptier older meant pavel byteblob benchmarking regarding great unqualified
wanted thoughts europeu astonished acceptable blobtable retrieval wasn demonstrate wanted thoughts europeu astonished acceptable blobtable retrieval wasn demonstrate
incidentally brutal carefully pervasive testlob mydatetime antonio casqueiro sybase fourth incidentally brutal carefully pervasive testlob mydatetime antonio casqueiro sybase fourth
pad microsystems dullesopen rpad spot lpad ganelin sssz testabc pst dumping lots pad microsystems dullesopen rpad spot lpad ganelin sssz testabc pst dumping lots
### evaluatable > evaluable ### evaluatable > evaluable
chdh biz inventec chdh biz inventec
enclosing mostly dtp scrolls cars splitting replay incomplete automate enclosing mostly dtp scrolls cars splitting replay incomplete automate
shorten shorten
attrdef resut reltuples indrelid tuple adrelid rolconfig relnamespace attname rolpassword atttypid attrdef resut reltuples indrelid tuple adrelid rolconfig relnamespace attname rolpassword atttypid
represented rolname indisprimary tablespace proname rolconnlimit currtid indexdef rolcreatedb represented rolname indisprimary tablespace proname rolconnlimit currtid indexdef rolcreatedb
indexrelid datdba datname adnum tgnargs attnum relam userbyid typbasetype attlen rolcanlogin indexrelid datdba datname adnum tgnargs attnum relam userbyid typbasetype attlen rolcanlogin
rolinherit adsrc usecreatedb superuser indexprs tgfoid indisunique spcname cleartext relpages rolinherit adsrc usecreatedb superuser indexprs tgfoid indisunique spcname cleartext relpages
usesuper pgdocs tginitdeferred objoid datestyle indisclustered usename datconfig tgargs resize usesuper pgdocs tginitdeferred objoid datestyle indisclustered usename datconfig tgargs resize
tgconstrrelid classoid relhasoids pretty portals rolcatupdate rolsuper spcowner typname cet typlen tgconstrrelid classoid relhasoids pretty portals rolcatupdate rolsuper spcowner typname cet typlen
latin tgconstrname datallowconn atttypmod dattablespace attrelid ctid timestamptz atthasdef latin tgconstrname datallowconn atttypmod dattablespace attrelid ctid timestamptz atthasdef
nspname objsubid typnamespace rolcreaterole tgrelid spclocation relhasrules dont indkey postmaster nspname objsubid typnamespace rolcreaterole tgrelid spclocation relhasrules dont indkey postmaster
relkind autovacuum datlastsysoid attisdropped amname datacl deallocate tgdeferrable stats relkind autovacuum datlastsysoid attisdropped amname datacl deallocate tgdeferrable stats
spcacl relname rolvaliduntil attnotnull authid aclitem spcacl relname rolvaliduntil attnotnull authid aclitem
plpgsql interrupting spring oids plperl regex newest plpgsql interrupting spring oids plperl regex newest
xhtml transactionally remotly jnlp launch mirror subversion matcher hoohoho matching bulk xhtml transactionally remotly jnlp launch mirror subversion matcher hoohoho matching bulk
...@@ -506,7 +506,7 @@ lightweight builder ...@@ -506,7 +506,7 @@ lightweight builder
tunes elephant codewave incorrectly mytunesrss speeds cte honoured httpdocs department whereever dog dept edh oops flower music appends research plant tunes elephant codewave incorrectly mytunesrss speeds cte honoured httpdocs department whereever dog dept edh oops flower music appends research plant
testview gaps birth vid weblog blojsom unsubscribe testview gaps birth vid weblog blojsom unsubscribe
imports bnot severity colon braces suppress star bxor band bor unary bsr puppy lor rcurly lcurly puppycrawl crawl ctor subclasses ell slist lnot land unchecked curly dtds question imports bnot severity colon braces suppress star bxor band bor unary bsr puppy lor rcurly lcurly puppycrawl crawl ctor subclasses ell slist lnot land unchecked curly dtds question
forge chr trunc gabealbert tunebackup manifest forge chr trunc gabealbert tunebackup manifest
lumber thus taking repositories ago delegated mention leaks pgsql seeded felt efficiently mill mentioned forgot leaked restarted clearing occupies randomness warn implementing abstraction lumber thus taking repositories ago delegated mention leaks pgsql seeded felt efficiently mill mentioned forgot leaked restarted clearing occupies randomness warn implementing abstraction
spfile svr pkey synced semicolon terminating spfile svr pkey synced semicolon terminating
framework constructing architectural jmatter workgroup upgraded naked stopper skipping assumed framework constructing architectural jmatter workgroup upgraded naked stopper skipping assumed
...@@ -515,4 +515,5 @@ uklinux credential crypt kerberos redferni routine reopen tmp configured replica ...@@ -515,4 +515,5 @@ uklinux credential crypt kerberos redferni routine reopen tmp configured replica
webtest einstellung redirects endless ran gives replication lxabcdef asf packages replayed jspa webtest einstellung redirects endless ran gives replication lxabcdef asf packages replayed jspa
russian backward alexahin vlad ffffffffffff bfff ffffffff webapp undeploy initializer brasil uncached slowing translating uploaded russian backward alexahin vlad ffffffffffff bfff ffffffff webapp undeploy initializer brasil uncached slowing translating uploaded
llc computing oliver road inaccessible android velasques duplicates eduardo chunk brazilian near langpair xrmd xmkd llc computing oliver road inaccessible android velasques duplicates eduardo chunk brazilian near langpair xrmd xmkd
encapsulates negating igor midnight fulfill prefixes communicates nesting convenience negated resides optimizing principal applets dobrovolskyi
\ No newline at end of file involves ukrainian chile machines restricting summer aliased backus naur
\ No newline at end of file
...@@ -36,7 +36,7 @@ import org.h2.util.StringUtils; ...@@ -36,7 +36,7 @@ import org.h2.util.StringUtils;
public class PrepareTranslation { public class PrepareTranslation {
private static final String MAIN_LANGUAGE = "en"; private static final String MAIN_LANGUAGE = "en";
private static final String DELETED_PREFIX = "~"; private static final String DELETED_PREFIX = "~";
private static final boolean AUTO_TRANSLATE = true; private static final boolean AUTO_TRANSLATE = false;
public static void main(String[] args) throws Exception { public static void main(String[] args) throws Exception {
new PrepareTranslation().run(args); new PrepareTranslation().run(args);
...@@ -431,7 +431,13 @@ public class PrepareTranslation { ...@@ -431,7 +431,13 @@ public class PrepareTranslation {
if (!p.containsKey(key)) { if (!p.containsKey(key)) {
String t = oldTranslations.getProperty(now); String t = oldTranslations.getProperty(now);
if (t == null) { if (t == null) {
toTranslate.add(key); if (AUTO_TRANSLATE) {
toTranslate.add(key);
} else {
System.out.println(trans.getName() + ": key " + key + " not found in translation file; added dummy # 'translation'");
t = "#" + now;
p.put(key, t);
}
} else { } else {
p.put(key, t); p.put(key, t);
} }
...@@ -451,8 +457,13 @@ public class PrepareTranslation { ...@@ -451,8 +457,13 @@ public class PrepareTranslation {
// main data changed since the last run: review translation // main data changed since the last run: review translation
System.out.println(trans.getName() + ": key " + key + " changed, please review; last=" + last System.out.println(trans.getName() + ": key " + key + " changed, please review; last=" + last
+ " now=" + now); + " now=" + now);
// String old = p.getProperty(key); if (AUTO_TRANSLATE) {
toTranslate.add(key); toTranslate.add(key);
} else {
String old = p.getProperty(key);
t = "#" + now + " #" + old;
p.put(key, t);
}
} else { } else {
p.put(key, t); p.put(key, t);
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论