Skip to content
项目
群组
代码片段
帮助
正在加载...
帮助
为 GitLab 提交贡献
登录/注册
切换导航
H
h2database
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
计划
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
Administrator
h2database
Commits
8558795d
提交
8558795d
authored
5月 21, 2009
作者:
Thomas Mueller
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
remove unnecessary throws clauses
上级
0ccda3fb
显示空白字符变更
内嵌
并排
正在显示
27 个修改的文件
包含
56 行增加
和
37 行删除
+56
-37
Prepared.java
h2/src/main/org/h2/command/Prepared.java
+2
-0
SelectListColumnResolver.java
h2/src/main/org/h2/command/dml/SelectListColumnResolver.java
+1
-3
ConstraintCheck.java
h2/src/main/org/h2/constraint/ConstraintCheck.java
+1
-1
ConstraintReferential.java
h2/src/main/org/h2/constraint/ConstraintReferential.java
+1
-1
ConstraintUnique.java
h2/src/main/org/h2/constraint/ConstraintUnique.java
+1
-1
Database.java
h2/src/main/org/h2/engine/Database.java
+1
-1
FunctionAlias.java
h2/src/main/org/h2/engine/FunctionAlias.java
+2
-2
Session.java
h2/src/main/org/h2/engine/Session.java
+1
-1
SessionRemote.java
h2/src/main/org/h2/engine/SessionRemote.java
+1
-1
Expression.java
h2/src/main/org/h2/expression/Expression.java
+2
-0
JavaFunction.java
h2/src/main/org/h2/expression/JavaFunction.java
+1
-1
TableFunction.java
h2/src/main/org/h2/expression/TableFunction.java
+1
-1
FullText.java
h2/src/main/org/h2/fulltext/FullText.java
+2
-2
BaseIndex.java
h2/src/main/org/h2/index/BaseIndex.java
+10
-0
BtreePage.java
h2/src/main/org/h2/index/BtreePage.java
+1
-0
Index.java
h2/src/main/org/h2/index/Index.java
+0
-1
PageBtree.java
h2/src/main/org/h2/index/PageBtree.java
+1
-1
JdbcXAConnection.java
h2/src/main/org/h2/jdbcx/JdbcXAConnection.java
+1
-1
WebServlet.java
h2/src/main/org/h2/server/web/WebServlet.java
+1
-2
FileLock.java
h2/src/main/org/h2/store/FileLock.java
+1
-1
PageFreeList.java
h2/src/main/org/h2/store/PageFreeList.java
+7
-8
Record.java
h2/src/main/org/h2/store/Record.java
+2
-0
FileObjectDiskMapped.java
h2/src/main/org/h2/store/fs/FileObjectDiskMapped.java
+3
-3
FileObjectSplit.java
h2/src/main/org/h2/store/fs/FileObjectSplit.java
+3
-3
FileSystemMemory.java
h2/src/main/org/h2/store/fs/FileSystemMemory.java
+1
-1
SoftHashMap.java
h2/src/main/org/h2/util/SoftHashMap.java
+1
-1
Value.java
h2/src/main/org/h2/value/Value.java
+7
-0
没有找到文件。
h2/src/main/org/h2/command/Prepared.java
浏览文件 @
8558795d
...
...
@@ -176,6 +176,8 @@ public abstract class Prepared {
/**
* Prepare this statement.
*
* @throws SQLException
*/
public
void
prepare
()
throws
SQLException
{
// nothing to do
...
...
h2/src/main/org/h2/command/dml/SelectListColumnResolver.java
浏览文件 @
8558795d
...
...
@@ -6,8 +6,6 @@
*/
package
org
.
h2
.
command
.
dml
;
import
java.sql.SQLException
;
import
org.h2.expression.Expression
;
import
org.h2.expression.ExpressionColumn
;
import
org.h2.table.Column
;
...
...
@@ -71,7 +69,7 @@ public class SelectListColumnResolver implements ColumnResolver {
return
null
;
}
public
Value
getValue
(
Column
column
)
throws
SQLException
{
public
Value
getValue
(
Column
column
)
{
return
null
;
}
...
...
h2/src/main/org/h2/constraint/ConstraintCheck.java
浏览文件 @
8558795d
...
...
@@ -143,7 +143,7 @@ public class ConstraintCheck extends Constraint {
return
null
;
}
public
void
rebuild
()
throws
SQLException
{
public
void
rebuild
()
{
// nothing to do
}
...
...
h2/src/main/org/h2/constraint/ConstraintReferential.java
浏览文件 @
8558795d
...
...
@@ -533,7 +533,7 @@ public class ConstraintReferential extends Constraint {
updateSQL
=
buff
.
toString
();
}
public
void
rebuild
()
throws
SQLException
{
public
void
rebuild
()
{
buildUpdateSQL
();
buildDeleteSQL
();
}
...
...
h2/src/main/org/h2/constraint/ConstraintUnique.java
浏览文件 @
8558795d
...
...
@@ -148,7 +148,7 @@ public class ConstraintUnique extends Constraint {
return
index
;
}
public
void
rebuild
()
throws
SQLException
{
public
void
rebuild
()
{
// nothing to do
}
...
...
h2/src/main/org/h2/engine/Database.java
浏览文件 @
8558795d
...
...
@@ -486,7 +486,7 @@ public class Database implements DataHandler {
* @param testHash the hash code
* @return true if the cipher algorithm and the password match
*/
public
boolean
validateFilePasswordHash
(
String
testCipher
,
byte
[]
testHash
)
throws
SQLException
{
public
boolean
validateFilePasswordHash
(
String
testCipher
,
byte
[]
testHash
)
{
if
(!
StringUtils
.
equals
(
testCipher
,
this
.
cipher
))
{
return
false
;
}
...
...
h2/src/main/org/h2/engine/FunctionAlias.java
浏览文件 @
8558795d
...
...
@@ -322,7 +322,7 @@ public class FunctionAlias extends DbObjectBase {
}
}
public
Class
[]
getColumnClasses
()
throws
SQLException
{
public
Class
[]
getColumnClasses
()
{
return
method
.
getParameterTypes
();
}
...
...
@@ -330,7 +330,7 @@ public class FunctionAlias extends DbObjectBase {
return
dataType
;
}
public
int
getParameterCount
()
throws
SQLException
{
public
int
getParameterCount
()
{
return
paramCount
;
}
...
...
h2/src/main/org/h2/engine/Session.java
浏览文件 @
8558795d
...
...
@@ -629,7 +629,7 @@ public class Session extends SessionWithState {
}
}
private
void
unlockAll
()
throws
SQLException
{
private
void
unlockAll
()
{
if
(
SysProperties
.
CHECK
)
{
if
(
undoLog
.
size
()
>
0
)
{
Message
.
throwInternalError
();
...
...
h2/src/main/org/h2/engine/SessionRemote.java
浏览文件 @
8558795d
...
...
@@ -87,7 +87,7 @@ public class SessionRemote extends SessionWithState implements SessionFactory, D
// nothing to do
}
private
SessionRemote
(
ConnectionInfo
ci
)
throws
SQLException
{
private
SessionRemote
(
ConnectionInfo
ci
)
{
this
.
connectionInfo
=
ci
;
}
...
...
h2/src/main/org/h2/expression/Expression.java
浏览文件 @
8558795d
...
...
@@ -193,6 +193,7 @@ public abstract class Expression {
*
* @param session the session
* @param filter the table filter
* @throws SQLException
*/
public
void
createIndexConditions
(
Session
session
,
TableFilter
filter
)
throws
SQLException
{
// default is do nothing
...
...
@@ -300,6 +301,7 @@ public abstract class Expression {
* @param session the session
* @param select the query
* @return the optimized expression
* @throws SQLException
*/
public
Expression
optimizeInJoin
(
Session
session
,
Select
select
)
throws
SQLException
{
return
this
;
...
...
h2/src/main/org/h2/expression/JavaFunction.java
浏览文件 @
8558795d
...
...
@@ -109,7 +109,7 @@ public class JavaFunction extends Expression implements FunctionCall {
return
functionAlias
.
getName
();
}
public
int
getParameterCount
()
throws
SQLException
{
public
int
getParameterCount
()
{
return
javaMethod
.
getParameterCount
();
}
...
...
h2/src/main/org/h2/expression/TableFunction.java
浏览文件 @
8558795d
...
...
@@ -26,7 +26,7 @@ import org.h2.value.ValueResultSet;
/**
* Implementation of the functions TABLE(..) and TABLE_DISTINCT(..).
*/
public
class
TableFunction
extends
Function
implements
FunctionCall
{
public
class
TableFunction
extends
Function
{
private
final
boolean
distinct
;
private
final
long
rowCount
;
private
Column
[]
columnList
;
...
...
h2/src/main/org/h2/fulltext/FullText.java
浏览文件 @
8558795d
...
...
@@ -793,14 +793,14 @@ public class FullText {
/**
* INTERNAL
*/
public
void
close
()
throws
SQLException
{
public
void
close
()
{
setting
.
removeIndexInfo
(
index
);
}
/**
* INTERNAL
*/
public
void
remove
()
throws
SQLException
{
public
void
remove
()
{
setting
.
removeIndexInfo
(
index
);
}
...
...
h2/src/main/org/h2/index/BaseIndex.java
浏览文件 @
8558795d
...
...
@@ -174,6 +174,16 @@ public abstract class BaseIndex extends SchemaObjectBase implements Index {
return
false
;
}
/**
* Find a row or a list of rows that is larger and create a cursor to
* iterate over the result. The base implementation doesn't support this feature.
*
* @param session the session
* @param higherThan the lower limit (excluding)
* @param last the last row, or null for no limit
* @return the cursor
* @throws SQLException
*/
public
Cursor
findNext
(
Session
session
,
SearchRow
first
,
SearchRow
last
)
throws
SQLException
{
throw
Message
.
throwInternalError
();
}
...
...
h2/src/main/org/h2/index/BtreePage.java
浏览文件 @
8558795d
...
...
@@ -138,6 +138,7 @@ public abstract class BtreePage extends Record {
*
* @param i the index
* @return the row
* @throws SQLException
*/
SearchRow
getData
(
int
i
)
throws
SQLException
{
return
(
SearchRow
)
pageData
.
get
(
i
);
...
...
h2/src/main/org/h2/index/Index.java
浏览文件 @
8558795d
...
...
@@ -122,7 +122,6 @@ public interface Index extends SchemaObject {
* @param last the last row, or null for no limit
* @return the cursor
*/
Cursor
findNext
(
Session
session
,
SearchRow
higherThan
,
SearchRow
last
)
throws
SQLException
;
/**
...
...
h2/src/main/org/h2/index/PageBtree.java
浏览文件 @
8558795d
...
...
@@ -98,7 +98,7 @@ abstract class PageBtree extends Record {
int
comp
=
1
;
while
(
l
<
r
)
{
int
i
=
(
l
+
r
)
>>>
1
;
SearchRow
row
=
(
SearchRow
)
getRow
(
i
);
SearchRow
row
=
getRow
(
i
);
comp
=
index
.
compareRows
(
row
,
compare
);
if
(
comp
==
0
&&
add
)
{
if
(
index
.
indexType
.
getUnique
())
{
...
...
h2/src/main/org/h2/jdbcx/JdbcXAConnection.java
浏览文件 @
8558795d
...
...
@@ -477,7 +477,7 @@ implements XAConnection, XAResource
private
boolean
isClosed
;
public
PooledJdbcConnection
(
JdbcConnection
conn
)
throws
SQLException
{
public
PooledJdbcConnection
(
JdbcConnection
conn
)
{
super
(
conn
);
}
...
...
h2/src/main/org/h2/server/web/WebServlet.java
浏览文件 @
8558795d
...
...
@@ -15,7 +15,6 @@ import java.util.Enumeration;
import
java.util.Properties
;
import
javax.servlet.ServletConfig
;
import
javax.servlet.ServletException
;
import
javax.servlet.ServletOutputStream
;
import
javax.servlet.http.HttpServlet
;
import
javax.servlet.http.HttpServletRequest
;
...
...
@@ -32,7 +31,7 @@ public class WebServlet extends HttpServlet {
private
static
final
long
serialVersionUID
=
9171446624885086692L
;
private
transient
WebServer
server
;
public
void
init
()
throws
ServletException
{
public
void
init
()
{
ServletConfig
config
=
getServletConfig
();
Enumeration
en
=
config
.
getInitParameterNames
();
ArrayList
list
=
new
ArrayList
();
...
...
h2/src/main/org/h2/store/FileLock.java
浏览文件 @
8558795d
...
...
@@ -171,7 +171,7 @@ public class FileLock {
* @param key the key
* @param value the value
*/
public
void
setProperty
(
String
key
,
String
value
)
throws
SQLException
{
public
void
setProperty
(
String
key
,
String
value
)
{
if
(
value
==
null
)
{
properties
.
remove
(
key
);
}
else
{
...
...
h2/src/main/org/h2/store/PageFreeList.java
浏览文件 @
8558795d
...
...
@@ -114,7 +114,7 @@ public class PageFreeList extends Record {
return
-
1
;
}
return
next
.
allocate
(
pos
);
}
else
{
}
int
idx
=
pos
-
firstAddressed
;
if
(
idx
>=
0
&&
!
used
.
get
(
idx
))
{
used
.
set
(
pos
-
firstAddressed
);
...
...
@@ -122,7 +122,6 @@ public class PageFreeList extends Record {
}
return
pos
;
}
}
/**
* Add a page to the free list.
...
...
@@ -155,7 +154,7 @@ public class PageFreeList extends Record {
}
}
public
int
getByteCount
(
DataPage
dummy
)
throws
SQLException
{
public
int
getByteCount
(
DataPage
dummy
)
{
return
store
.
getPageSize
();
}
...
...
h2/src/main/org/h2/store/Record.java
浏览文件 @
8558795d
...
...
@@ -44,6 +44,8 @@ public abstract class Record extends CacheObject {
* If a read operation is required before writing, this needs to be done here.
* Because the data page buffer is shared for read and write operations.
* The method may read data and change the file pointer.
*
* @throws SQLException
*/
public
void
prepareWrite
()
throws
SQLException
{
// nothing to do
...
...
h2/src/main/org/h2/store/fs/FileObjectDiskMapped.java
浏览文件 @
8558795d
...
...
@@ -106,7 +106,7 @@ public class FileObjectDiskMapped implements FileObject {
file
=
null
;
}
public
long
getFilePointer
()
throws
IOException
{
public
long
getFilePointer
()
{
return
mapped
.
position
();
}
...
...
@@ -118,11 +118,11 @@ public class FileObjectDiskMapped implements FileObject {
return
file
.
length
();
}
public
void
readFully
(
byte
[]
b
,
int
off
,
int
len
)
throws
IOException
{
public
void
readFully
(
byte
[]
b
,
int
off
,
int
len
)
{
mapped
.
get
(
b
,
off
,
len
);
}
public
void
seek
(
long
pos
)
throws
IOException
{
public
void
seek
(
long
pos
)
{
mapped
.
position
((
int
)
pos
);
}
...
...
h2/src/main/org/h2/store/fs/FileObjectSplit.java
浏览文件 @
8558795d
...
...
@@ -38,11 +38,11 @@ public class FileObjectSplit implements FileObject {
}
}
public
long
getFilePointer
()
throws
IOException
{
public
long
getFilePointer
()
{
return
filePointer
;
}
public
long
length
()
throws
IOException
{
public
long
length
()
{
return
length
;
}
...
...
@@ -67,7 +67,7 @@ public class FileObjectSplit implements FileObject {
}
}
public
void
seek
(
long
pos
)
throws
IOException
{
public
void
seek
(
long
pos
)
{
filePointer
=
pos
;
}
...
...
h2/src/main/org/h2/store/fs/FileSystemMemory.java
浏览文件 @
8558795d
...
...
@@ -110,7 +110,7 @@ public class FileSystemMemory extends FileSystem {
}
}
public
void
deleteRecursive
(
String
fileName
)
throws
SQLException
{
public
void
deleteRecursive
(
String
fileName
)
{
fileName
=
normalize
(
fileName
);
synchronized
(
MEMORY_FILES
)
{
Iterator
it
=
MEMORY_FILES
.
keySet
().
iterator
();
...
...
h2/src/main/org/h2/util/SoftHashMap.java
浏览文件 @
8558795d
...
...
@@ -18,7 +18,7 @@ import java.util.Set;
* and removed. It is not a general purpose cache, as it doesn't implement some
* methods, and others not according to the map definition, to improve speed.
*/
public
class
SoftHashMap
extends
AbstractMap
implements
Map
{
public
class
SoftHashMap
extends
AbstractMap
{
private
Map
map
;
private
ReferenceQueue
queue
=
new
ReferenceQueue
();
...
...
h2/src/main/org/h2/value/Value.java
浏览文件 @
8558795d
...
...
@@ -858,6 +858,7 @@ public abstract class Value {
* @param onlyToSmallerScale if the scale should not reduced
* @param targetScale the requested scale
* @return the value
* @throws SQLException
*/
public
Value
convertScale
(
boolean
onlyToSmallerScale
,
int
targetScale
)
throws
SQLException
{
return
this
;
...
...
@@ -868,6 +869,7 @@ public abstract class Value {
*
* @param precision the new precision
* @return the new value
* @throws SQLException
*/
public
Value
convertPrecision
(
long
precision
)
throws
SQLException
{
return
this
;
...
...
@@ -922,6 +924,7 @@ public abstract class Value {
* @param handler the data handler
* @param tableId the table to link to
* @return the new value or itself
* @throws SQLException
*/
public
Value
link
(
DataHandler
handler
,
int
tableId
)
throws
SQLException
{
return
this
;
...
...
@@ -940,6 +943,8 @@ public abstract class Value {
/**
* Mark any underlying resource as 'not linked to any table'. For values
* that are kept fully in memory this method has no effect.
*
* @throws SQLException
*/
public
void
unlink
()
throws
SQLException
{
// nothing to do
...
...
@@ -958,6 +963,8 @@ public abstract class Value {
/**
* Close the underlying resource, if any. For values that are kept fully in
* memory this method has no effect.
*
* @throws SQLException
*/
public
void
close
()
throws
SQLException
{
// nothing to do
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论