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

Commit09634ea

Browse files
committed
Indent jdbc case labels using pgjindent.
1 parent6c8120d commit09634ea

32 files changed

+1236
-1211
lines changed

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

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -291,7 +291,6 @@ public importer(Connection db, String name, String dir)
291291

292292
publicvoidrun()
293293
{
294-
295294
// Now the real import stuff
296295
if (name !=null &&dir !=null)
297296
{

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

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -214,21 +214,21 @@ public void runTest()
214214
{
215215
switch (mode)
216216
{
217-
caseCREATE:
218-
log("Exception creating database",sqle);
219-
break;
220-
caseINSERT:
221-
log("Exception inserting block " +blockNum,sqle);
222-
break;
223-
caseSELECT:
224-
log("Exception selecting block " +blockNum,sqle);
225-
break;
226-
caseLIKE:
227-
log("Exception doing LIKE on block " +blockNum,sqle);
228-
break;
229-
default:
230-
log("Exception",sqle);
231-
break;
217+
caseCREATE:
218+
log("Exception creating database",sqle);
219+
break;
220+
caseINSERT:
221+
log("Exception inserting block " +blockNum,sqle);
222+
break;
223+
caseSELECT:
224+
log("Exception selecting block " +blockNum,sqle);
225+
break;
226+
caseLIKE:
227+
log("Exception doing LIKE on block " +blockNum,sqle);
228+
break;
229+
default:
230+
log("Exception",sqle);
231+
break;
232232
}
233233
}
234234
catch (ClassNotFoundExceptioncnfe)

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

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
/*
88
*
9-
* $Id: basic.java,v 1.9 2001/11/1922:43:13 momjian Exp $
9+
* $Id: basic.java,v 1.10 2001/11/1923:16:44 momjian Exp $
1010
*
1111
* This example tests the basic components of the JDBC driver, and shows
1212
* how even the simplest of queries can be implemented.
@@ -137,6 +137,7 @@ public void doexample() throws SQLException
137137
// Now run the query again, showing a more efficient way of getting the
138138
// result if you don't know what column number a value is in
139139

140+
140141
System.out.println("performing another query");
141142
rs =st.executeQuery("select * from basic where b>1");
142143
if (rs !=null)
@@ -163,6 +164,7 @@ public void doexample() throws SQLException
163164

164165
// Now test maxrows by setting it to 3 rows
165166

167+
166168
st.setMaxRows(3);
167169
System.out.println("performing a query limited to " +st.getMaxRows());
168170
rs =st.executeQuery("select a, b from basic");

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

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,6 @@ public blobtest(String args[]) throws ClassNotFoundException, FileNotFoundExcept
6161
System.out.println("Now closing the connection");
6262
s.close();
6363
db.close();
64-
6564
}
6665

6766
/*
@@ -171,7 +170,6 @@ private void ownapi_test3(int oid) throws SQLException
171170
lobj.unlink(oid);
172171
}
173172

174-
//=======================================================================
175173
// This tests the Blob interface of the JDBC 2.0 specification
176174
publicvoidjdbc2api(intoid)throwsSQLException,IOException
177175
{
@@ -218,8 +216,6 @@ private void jdbc2api_cleanup() throws SQLException
218216
db.setAutoCommit(false);
219217
}
220218

221-
//=======================================================================
222-
223219
publicstaticvoidinstructions()
224220
{
225221
System.err.println("java example.blobtest jdbc-url user password [debug]");

‎src/interfaces/jdbc/example/corba/StockClient.java

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
*
1010
* It has no GUI, just a text frontend to keep it simple.
1111
*
12-
* $Id: StockClient.java,v 1.3 2001/11/1922:43:13 momjian Exp $
12+
* $Id: StockClient.java,v 1.4 2001/11/1923:16:45 momjian Exp $
1313
*/
1414
publicclassStockClient
1515
{
@@ -116,29 +116,29 @@ private void mainMenu()
116116
inti =getMenu("Main",5);
117117
switch (i)
118118
{
119-
case0:
120-
run =false;
121-
break;
119+
case0:
120+
run =false;
121+
break;
122122

123-
case1:
124-
displayItem();
125-
break;
123+
case1:
124+
displayItem();
125+
break;
126126

127-
case2:
128-
bookOut();
129-
break;
127+
case2:
128+
bookOut();
129+
break;
130130

131-
case3:
132-
bookIn();
133-
break;
131+
case3:
132+
bookIn();
133+
break;
134134

135-
case4:
136-
order(0);
137-
break;
135+
case4:
136+
order(0);
137+
break;
138138

139-
case5:
140-
displayAll();
141-
break;
139+
case5:
140+
displayAll();
141+
break;
142142
}
143143
}
144144
}

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

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
*
1010
* To use this example, you need a database to be in existence. This example
1111
* will create a table called datestyle.
12-
*
1312
*/
1413

1514
publicclassdatestyle
@@ -105,7 +104,6 @@ public void init() throws SQLException
105104
ps.setDate(1,standard);
106105
ps.executeUpdate();
107106
ps.close();
108-
109107
}
110108

111109
/*

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

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,6 @@ public void processSlashCommand(String line) throws SQLException
218218
{
219219
if (line.startsWith("\\d"))
220220
{
221-
222221
if (line.startsWith("\\d "))
223222
{
224223
// Display details about a table

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

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ public psql(String args[]) throws ClassNotFoundException, FileNotFoundException,
5050
// Now the main loop.
5151
inttt =0,lineno =1;
5252
while (tt !=StreamTokenizer.TT_EOF && !done)
53-
{// done added by CWJ to permit \q command
53+
{
5454
System.out.print("[" +lineno +"] ");
5555
System.out.flush();
5656

@@ -72,7 +72,6 @@ public psql(String args[]) throws ClassNotFoundException, FileNotFoundException,
7272
System.out.println("Now closing the connection");
7373
st.close();
7474
db.close();
75-
7675
}
7776

7877
/*

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

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,6 @@ public threadsafe(String args[]) throws ClassNotFoundException, FileNotFoundExce
5353
System.out.println("Now closing the connection");
5454
st.close();
5555
db.close();
56-
5756
}
5857

5958
/*
@@ -108,7 +107,6 @@ public void doexample() throws SQLException
108107
System.out.println("Waiting for threads to run");
109108
while (thread1.isAlive() ||thread2.isAlive() ||thread3.isAlive())
110109
thread0.yield();
111-
112110
}
113111
finally
114112
{

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp