本文整理汇总了Java中org.hsqldb.result.ResultMetaData.emptyResultMetaData方法的典型用法代码示例。如果您正苦于以下问题:Java ResultMetaData.emptyResultMetaData方法的具体用法?Java ResultMetaData.emptyResultMetaData怎么用?Java ResultMetaData.emptyResultMetaData使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.hsqldb.result.ResultMetaData
的用法示例。
在下文中一共展示了ResultMetaData.emptyResultMetaData方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getResultMetaData
import org.hsqldb.result.ResultMetaData; //导入方法依赖的package包/类
/**
* Returns the metadata, which is empty if the CompiledStatement does not
* generate a Result.
*/
public ResultMetaData getResultMetaData() {
switch (type) {
case StatementTypes.DELETE_WHERE :
case StatementTypes.INSERT :
case StatementTypes.UPDATE_WHERE :
return ResultMetaData.emptyResultMetaData;
default :
throw Error.runtimeError(
ErrorCode.U_S0500,
"CompiledStatement.getResultMetaData()");
}
}
示例2: getResultMetaData
import org.hsqldb.result.ResultMetaData; //导入方法依赖的package包/类
/**
* Returns the metadata, which is empty if the CompiledStatement does not
* generate a Result.
*/
public ResultMetaData getResultMetaData() {
switch (type) {
case StatementTypes.DELETE_WHERE :
case StatementTypes.INSERT :
case StatementTypes.UPDATE_WHERE :
case StatementTypes.MERGE :
return ResultMetaData.emptyResultMetaData;
default :
throw Error.runtimeError(ErrorCode.U_S0500, "StatementDMQL");
}
}
示例3: getResultMetaData
import org.hsqldb.result.ResultMetaData; //导入方法依赖的package包/类
public ResultMetaData getResultMetaData() {
if (resultMetaData != null) {
return resultMetaData;
}
switch (type) {
case StatementTypes.CALL : {
if (expression == null) {
return ResultMetaData.emptyResultMetaData;
}
// TODO:
//
// 1.) standard to register metadata for columns of
// the primary result set, if any, generated by call
//
// 2.) Represent the return value, if any (which is
// not, in truth, a result set), as an OUT parameter
//
// For now, I've reverted a bunch of code I had in place
// and instead simply reflect things as the are, describing
// a single column result set that communicates
// the return value. If the expression generating the
// return value has a void return type, a result set
// is described whose single column is of type NULL
ResultMetaData md = ResultMetaData.newResultMetaData(1);
ColumnBase column =
new ColumnBase(null, null, null,
StatementDMQL.RETURN_COLUMN_NAME);
column.setType(expression.getDataType());
md.columns[0] = column;
md.prepareData();
resultMetaData = md;
return md;
}
default :
throw Error.runtimeError(ErrorCode.U_S0500,
"StatementProcedure");
}
}
示例4: getResultMetaData
import org.hsqldb.result.ResultMetaData; //导入方法依赖的package包/类
public ResultMetaData getResultMetaData() {
return ResultMetaData.emptyResultMetaData;
}
示例5: getResultMetaData
import org.hsqldb.result.ResultMetaData; //导入方法依赖的package包/类
public ResultMetaData getResultMetaData() {
if (resultMetaData != null) {
return resultMetaData;
}
switch (type) {
case StatementTypes.CALL : {
if (expression == null) {
return ResultMetaData.emptyResultMetaData;
}
// TODO:
//
// 1.) standard to register metadata for columns of
// the primary result set, if any, generated by call
//
// 2.) Represent the return value, if any (which is
// not, in truth, a result set), as an OUT parameter
//
// For now, I've reverted a bunch of code I had in place
// and instead simply reflect things as the are, describing
// a single column result set that communicates
// the return value. If the expression generating the
// return value has a void return type, a result set
// is described whose single column is of type NULL
ResultMetaData md = ResultMetaData.newResultMetaData(1);
ColumnBase column =
new ColumnBase(null, null, null,
StatementDMQL.RETURN_COLUMN_NAME);
column.setType(expression.getDataType());
md.columns[0] = column;
md.prepareData();
resultMetaData = md;
return md;
}
default :
throw Error.runtimeError(
ErrorCode.U_S0500,
"CompiledStatement.getResultMetaData()");
}
}