Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit20f0cfc

Browse files
author
Peter Mount
committed
Fixed Internationalization of error messages.
1 parent3f59cc0 commit20f0cfc

File tree

4 files changed

+18
-9
lines changed

4 files changed

+18
-9
lines changed

‎src/interfaces/jdbc/CHANGELOG

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
Tue May 18 00:00:00 BST 1999
2+
- Just after committing, I realised why internationalisation isn't
3+
working. This is now fixed (in the Makefile).
4+
15
Mon May 17 23:40:00 BST 1999
26
- PG_Stream.close() now attempts to send the close connection message
37
to the backend before closing the streams

‎src/interfaces/jdbc/Makefile

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# Makefile for Java JDBC interface
55
#
66
# IDENTIFICATION
7-
# $Header: /cvsroot/pgsql/src/interfaces/jdbc/Attic/Makefile,v 1.12 1999/01/25 21:22:02 scrappy Exp $
7+
# $Header: /cvsroot/pgsql/src/interfaces/jdbc/Attic/Makefile,v 1.13 1999/05/1722:58:18 peter Exp $
88
#
99
#-------------------------------------------------------------------------
1010

@@ -69,6 +69,8 @@ OBJ_COMMON=postgresql/Connection.class \
6969
postgresql/Field.class\
7070
postgresql/PG_Stream.class\
7171
postgresql/ResultSet.class\
72+
postgresql/errors.properties\
73+
postgresql/errors_fr.properties\
7274
postgresql/fastpath/Fastpath.class\
7375
postgresql/fastpath/FastpathArg.class\
7476
postgresql/geometric/PGbox.class\
@@ -83,6 +85,7 @@ OBJ_COMMON=postgresql/Connection.class \
8385
postgresql/util/PGmoney.class\
8486
postgresql/util/PGobject.class\
8587
postgresql/util/PGtokenizer.class\
88+
postgresql/util/PSQLException.class\
8689
postgresql/util/Serialize.class\
8790
postgresql/util/UnixCrypt.class
8891

@@ -140,7 +143,8 @@ jdbc2:$(OBJ_COMMON) $(OBJ_JDBC2) postgresql.jar
140143
#directory. We use this later for compiling the dual-mode driver.
141144
#
142145
postgresql.jar:$(OBJ)$(OBJ_COMMON)
143-
$(JAR) -c0f$@$$($(FIND) postgresql -name "*.class" -print)
146+
$(JAR) -c0f$@$$($(FIND) postgresql -name "*.class" -print)\
147+
$(wildcard postgresql/*.properties)
144148

145149
# This rule removes any temporary and compiled files from the source tree.
146150
clean:

‎src/interfaces/jdbc/example/basic.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ public basic(String args[]) throws ClassNotFoundException, FileNotFoundException
4848
st.close();
4949
db.close();
5050

51+
//throw postgresql.Driver.notImplemented();
5152
}
5253

5354
/**

‎src/interfaces/jdbc/postgresql/Driver.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
// working quite to plan, so the class exists in the source, but it's not
99
// quite implemented yet. Peter May 17 1999.
1010
//
11-
//import postgresql.util.PSQLException;
11+
importpostgresql.util.PSQLException;
1212

1313
/**
1414
* The Java SQL framework allows for multiple database drivers. Each
@@ -108,11 +108,11 @@ public java.sql.Connection connect(String url, Properties info) throws SQLExcept
108108
con.openConnection (host(),port(),props,database(),url,this);
109109
return (java.sql.Connection)con;
110110
}catch(ClassNotFoundExceptionex) {
111-
//throw new PSQLException("postgresql.jvm.version",ex);
112-
thrownewSQLException("The postgresql.jar file does not contain the correct JDBC classes for this JVM. Try rebuilding.\nException thrown was "+ex.toString());
111+
thrownewPSQLException("postgresql.jvm.version",ex);
112+
//throw new SQLException("The postgresql.jar file does not contain the correct JDBC classes for this JVM. Try rebuilding.\nException thrown was "+ex.toString());
113113
}catch(Exceptionex2) {
114-
//throw new PSQLException("postgresql.unusual",ex2);
115-
thrownewSQLException("Something unusual has occured to cause the driver to fail. Please report this exception: "+ex2.toString());
114+
thrownewPSQLException("postgresql.unusual",ex2);
115+
//throw new SQLException("Something unusual has occured to cause the driver to fail. Please report this exception: "+ex2.toString());
116116
}
117117
// The old call - remove before posting
118118
//return new Connection (host(), port(), props, database(), url, this);
@@ -355,8 +355,8 @@ public String property(String name)
355355
*/
356356
publicstaticSQLExceptionnotImplemented()
357357
{
358-
//return new PSQLException("postgresql.unimplemented");
359-
returnnewSQLException("This method is not yet implemented.");
358+
returnnewPSQLException("postgresql.unimplemented");
359+
//return new SQLException("This method is not yet implemented.");
360360
}
361361
}
362362

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp