Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录/注册
切换导航
H
h2database
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
Administrator
h2database
Commits
189775e1
提交
189775e1
authored
7月 08, 2010
作者:
Thomas Mueller
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Checkstyle.
上级
4bd2e81a
显示空白字符变更
内嵌
并排
正在显示
10 个修改的文件
包含
105 行增加
和
96 行删除
+105
-96
checkstyle.xml
h2/src/installer/checkstyle.xml
+85
-77
AlterSchemaRename.java
h2/src/main/org/h2/command/ddl/AlterSchemaRename.java
+2
-2
CreateView.java
h2/src/main/org/h2/command/ddl/CreateView.java
+5
-3
DbUpgrade.java
h2/src/main/org/h2/upgrade/DbUpgrade.java
+1
-1
DbUpgradeNonPageStoreToCurrent.java
...c/main/org/h2/upgrade/DbUpgradeNonPageStoreToCurrent.java
+3
-3
Utils.java
h2/src/main/org/h2/util/Utils.java
+1
-2
TestMultiDimension.java
h2/src/test/org/h2/test/db/TestMultiDimension.java
+4
-4
TestNestedJoins.java
h2/src/test/org/h2/test/db/TestNestedJoins.java
+2
-2
TestUndoLogLarge.java
h2/src/test/org/h2/test/todo/TestUndoLogLarge.java
+1
-1
UpgradeCreator.java
h2/src/tools/org/h2/build/upgrade/UpgradeCreator.java
+1
-1
没有找到文件。
h2/src/installer/checkstyle.xml
浏览文件 @
189775e1
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE module PUBLIC "-//Puppy Crawl//DTD Check Configuration 1.3//EN" "http://www.puppycrawl.com/dtds/configuration_1_3.dtd">
<!--
This configuration file was written by the eclipse-cs plugin configuration editor
-->
...
...
@@ -6,7 +8,6 @@
Checkstyle-Configuration: MyCheckstyle
Description: none
-->
<!DOCTYPE module PUBLIC "-//Puppy Crawl//DTD Check Configuration 1.2//EN" "http://www.puppycrawl.com/dtds/configuration_1_2.dtd">
<module
name=
"Checker"
>
<property
name=
"severity"
value=
"warning"
/>
<module
name=
"TreeWalker"
>
...
...
@@ -31,10 +32,11 @@
</module>
<module
name=
"NoWhitespaceBefore"
/>
<module
name=
"OperatorWrap"
>
<property
name=
"tokens"
value=
"BAND,BOR,BSR,BXOR,COLON,DIV,EQUAL,GE,GT,LAND,LE,LITERAL_INSTANCEOF,LOR,LT,MINUS,MOD,NOT_EQUAL,SL,SR,STAR"
/>
<property
name=
"severity"
value=
"ignore"
/>
<property
name=
"tokens"
value=
"BAND,BOR,BSR,BXOR,COLON,DIV,EQUAL,GE,GT,LAND,LE,LITERAL_INSTANCEOF,LT,MINUS,MOD,NOT_EQUAL,SL,SR,STAR"
/>
<metadata
name=
"net.sf.eclipsecs.core.lastEnabledSeverity"
value=
"inherit"
/>
</module>
<module
name=
"ParenPad"
/>
<module
name=
"TabCharacter"
/>
<module
name=
"WhitespaceAfter"
/>
<module
name=
"WhitespaceAround"
>
<property
name=
"tokens"
value=
"ASSIGN,BAND,BAND_ASSIGN,BOR,BOR_ASSIGN,BSR,BSR_ASSIGN,BXOR,BXOR_ASSIGN,DIV_ASSIGN,EQUAL,GE,GT,LAND,LE,LITERAL_ASSERT,LITERAL_CATCH,LITERAL_DO,LITERAL_ELSE,LITERAL_FINALLY,LITERAL_FOR,LITERAL_IF,LITERAL_RETURN,LITERAL_SYNCHRONIZED,LITERAL_TRY,LITERAL_WHILE,LOR,LT,MINUS,MINUS_ASSIGN,MOD,MOD_ASSIGN,NOT_EQUAL,PLUS_ASSIGN,SL,SLIST,SL_ASSIGN,SR,SR_ASSIGN,STAR,STAR_ASSIGN,LITERAL_ASSERT,TYPE_EXTENSION_AND,WILDCARD_TYPE"
/>
...
...
@@ -62,11 +64,11 @@
<module
name=
"ArrayTypeStyle"
/>
<module
name=
"GenericIllegalRegexp"
>
<property
name=
"severity"
value=
"ignore"
/>
<property
name=
"format"
value=
"\s+$"
/>
<property
name=
"message"
value=
"Line has trailing spaces."
/>
<metadata
name=
"net.sf.eclipsecs.core.lastEnabledSeverity"
value=
"inherit"
/>
</module>
<module
name=
"TodoComment"
>
<property
name=
"severity"
value=
"ignore"
/>
<metadata
name=
"net.sf.eclipsecs.core.lastEnabledSeverity"
value=
"inherit"
/>
</module>
<module
name=
"UpperEll"
/>
<module
name=
"JavadocType"
/>
...
...
@@ -80,12 +82,18 @@
<module
name=
"SuperClone"
/>
<module
name=
"UnnecessaryParentheses"
/>
<module
name=
"TrailingComment"
/>
<module
name=
"PackageHtml"
>
<property
name=
"severity"
value=
"ignore"
/>
<metadata
name=
"net.sf.eclipsecs.core.lastEnabledSeverity"
value=
"inherit"
/>
</module>
<module
name=
"NewlineAtEndOfFile"
>
</module>
<module
name=
"FileTabCharacter"
>
<property
name=
"severity"
value=
"ignore"
/>
<metadata
name=
"net.sf.eclipsecs.core.lastEnabledSeverity"
value=
"inherit"
/>
</module>
<module
name=
"Translation"
/>
<module
name=
"PackageHtml"
>
<module
name=
"NewlineAtEndOfFile"
>
<property
name=
"severity"
value=
"ignore"
/>
<metadata
name=
"net.sf.eclipsecs.core.lastEnabledSeverity"
value=
"inherit"
/>
</module>
<module
name=
"Translation"
/>
</module>
h2/src/main/org/h2/command/ddl/AlterSchemaRename.java
浏览文件 @
189775e1
...
...
@@ -28,8 +28,8 @@ public class AlterSchemaRename extends DefineCommand {
super
(
session
);
}
public
void
setOldSchema
(
Schema
S
chema
)
{
oldSchema
=
S
chema
;
public
void
setOldSchema
(
Schema
s
chema
)
{
oldSchema
=
s
chema
;
}
public
void
setNewName
(
String
name
)
{
...
...
h2/src/main/org/h2/command/ddl/CreateView.java
浏览文件 @
189775e1
...
...
@@ -167,9 +167,11 @@ public class CreateView extends SchemaCommand {
}
}
// Class that holds a snapshot of dependent view information.
// We can't just work with TableViews directly because they become invalid
// when we drop the parent view.
/**
* Class that holds a snapshot of dependent view information. We can't just
* work with TableViews directly because they become invalid when we drop
* the parent view.
*/
private
class
DependentView
{
String
viewName
;
String
createSql
;
...
...
h2/src/main/org/h2/upgrade/DbUpgrade.java
浏览文件 @
189775e1
...
...
@@ -37,7 +37,7 @@ public class DbUpgrade {
* @param info The connection Properties
* @throws SQLException
*/
public
s
ynchronized
static
void
upgrade
(
String
url
,
Properties
info
)
throws
SQLException
{
public
s
tatic
synchronized
void
upgrade
(
String
url
,
Properties
info
)
throws
SQLException
{
if
(
nonPageStoreToCurrentEnabled
)
{
upgradeFromNonPageStore
(
url
,
info
);
}
...
...
h2/src/main/org/h2/upgrade/DbUpgradeNonPageStoreToCurrent.java
浏览文件 @
189775e1
...
...
@@ -23,8 +23,8 @@ import org.h2.util.Utils;
*/
public
class
DbUpgradeNonPageStoreToCurrent
{
private
static
boolean
scriptInTmpDir
=
false
;
private
static
boolean
deleteOldDb
=
false
;
private
static
boolean
scriptInTmpDir
;
private
static
boolean
deleteOldDb
;
private
String
url
;
private
Properties
info
;
...
...
h2/src/main/org/h2/util/Utils.java
浏览文件 @
189775e1
...
...
@@ -15,7 +15,6 @@ import java.io.ObjectOutputStream;
import
java.lang.reflect.Constructor
;
import
java.lang.reflect.Method
;
import
java.lang.reflect.Modifier
;
import
java.sql.SQLException
;
import
java.util.ArrayList
;
import
java.util.HashMap
;
import
java.util.HashSet
;
...
...
@@ -625,7 +624,7 @@ public class Utils {
private
static
int
match
(
Class
<?>[]
params
,
Object
[]
values
)
{
if
(
params
.
length
==
values
.
length
)
{
int
points
=
1
;
for
(
int
i
=
0
;
i
<
params
.
length
;
i
++)
{
for
(
int
i
=
0
;
i
<
params
.
length
;
i
++)
{
Class
<?>
pc
=
getNonPrimitiveClass
(
params
[
i
]);
Class
<?>
vc
=
values
[
i
].
getClass
();
if
(
pc
==
vc
)
{
...
...
h2/src/test/org/h2/test/db/TestMultiDimension.java
浏览文件 @
189775e1
...
...
@@ -52,12 +52,12 @@ public class TestMultiDimension extends TestBase {
assertEquals
(
5
,
m
.
interleave
(
3
,
0
));
assertEquals
(
5
,
m
.
interleave
(
new
int
[]{
3
,
0
}));
assertEquals
(
10
,
m
.
interleave
(
0
,
3
));
assertEquals
(
10
,
m
.
interleave
(
new
int
[]
{
0
,
3
}));
long
v
=
(
(
long
)
Integer
.
MAX_VALUE
|
((
long
)
Integer
.
MAX_VALUE
<<
31L
)
);
assertEquals
(
10
,
m
.
interleave
(
new
int
[]
{
0
,
3
}));
long
v
=
(
long
)
Integer
.
MAX_VALUE
|
((
long
)
Integer
.
MAX_VALUE
<<
31L
);
assertEquals
(
v
,
m
.
interleave
(
Integer
.
MAX_VALUE
,
Integer
.
MAX_VALUE
));
assertEquals
(
v
,
m
.
interleave
(
new
int
[]
{
Integer
.
MAX_VALUE
,
Integer
.
MAX_VALUE
}));
assertEquals
(
v
,
m
.
interleave
(
new
int
[]
{
Integer
.
MAX_VALUE
,
Integer
.
MAX_VALUE
}));
Random
random
=
new
Random
(
1
);
for
(
int
i
=
0
;
i
<
1000
;
i
++)
{
for
(
int
i
=
0
;
i
<
1000
;
i
++)
{
int
x
=
random
.
nextInt
(
Integer
.
MAX_VALUE
),
y
=
random
.
nextInt
(
Integer
.
MAX_VALUE
);
v
=
m
.
interleave
(
new
int
[]
{
x
,
y
});
long
v2
=
m
.
interleave
(
x
,
y
);
...
...
h2/src/test/org/h2/test/db/TestNestedJoins.java
浏览文件 @
189775e1
...
...
@@ -104,7 +104,7 @@ public class TestNestedJoins extends TestBase {
}
}
Random
random
=
new
Random
(
1
);
for
(
int
i
=
0
;
i
<
10000
;
i
++)
{
for
(
int
i
=
0
;
i
<
10000
;
i
++)
{
StringBuilder
buff
=
new
StringBuilder
();
int
t
=
1
+
random
.
nextInt
(
9
);
buff
.
append
(
"select "
);
...
...
@@ -223,7 +223,7 @@ public class TestNestedJoins extends TestBase {
ArrayList
<
String
>
list
=
New
.
arrayList
();
while
(
rs
.
next
())
{
StringBuilder
buff
=
new
StringBuilder
();
for
(
int
i
=
0
;
i
<
rs
.
getMetaData
().
getColumnCount
();
i
++)
{
for
(
int
i
=
0
;
i
<
rs
.
getMetaData
().
getColumnCount
();
i
++)
{
if
(
i
>
0
)
{
buff
.
append
(
" "
);
}
...
...
h2/src/test/org/h2/test/todo/TestUndoLogLarge.java
浏览文件 @
189775e1
...
...
@@ -38,7 +38,7 @@ public class TestUndoLogLarge {
PreparedStatement
prep
=
conn
.
prepareStatement
(
"insert into test(name) values(space(1024*1024))"
);
long
time
=
System
.
currentTimeMillis
();
for
(
int
i
=
0
;
i
<
2500
;
i
++)
{
for
(
int
i
=
0
;
i
<
2500
;
i
++)
{
prep
.
execute
();
long
now
=
System
.
currentTimeMillis
();
if
(
now
>
time
+
5000
)
{
...
...
h2/src/tools/org/h2/build/upgrade/UpgradeCreator.java
浏览文件 @
189775e1
...
...
@@ -20,7 +20,7 @@ public class UpgradeCreator {
*
* @param args the command line parameters
*/
private
static
String
[]
TEXT_FILE_EXTENSIONS
=
{
".java"
,
".xml"
,
".bat"
,
".sh"
,
".txt"
,
".html"
,
".csv"
};
private
static
final
String
[]
TEXT_FILE_EXTENSIONS
=
{
".java"
,
".xml"
,
".bat"
,
".sh"
,
".txt"
,
".html"
,
".csv"
};
/**
* This method is called when executing this application from the command
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论