提交 a21b01f0 authored 作者: Noel Grandin's avatar Noel Grandin

javadoc and translation updates

上级 118c1481
...@@ -185,6 +185,9 @@ public class CommandContainer extends Command { ...@@ -185,6 +185,9 @@ public class CommandContainer extends Command {
return prepared.getType(); return prepared.getType();
} }
/**
* Clean up any associated CTE.
*/
void clearCTE() { void clearCTE() {
clearCTE(session, prepared); clearCTE(session, prepared);
} }
......
...@@ -17,6 +17,9 @@ import org.h2.util.Utils; ...@@ -17,6 +17,9 @@ import org.h2.util.Utils;
*/ */
public abstract class CommandWithValues extends Prepared { public abstract class CommandWithValues extends Prepared {
/**
* Expression data for the VALUES clause.
*/
protected final ArrayList<Expression[]> valuesExpressionList = Utils.newSmallArrayList(); protected final ArrayList<Expression[]> valuesExpressionList = Utils.newSmallArrayList();
/** /**
......
...@@ -222,6 +222,9 @@ public abstract class MVTempResult implements ResultExternal { ...@@ -222,6 +222,9 @@ public abstract class MVTempResult implements ResultExternal {
tempFileDeleter.deleteFile(fileRef, closeable); tempFileDeleter.deleteFile(fileRef, closeable);
} }
/**
* If any value in the rows is a ValueEnum, apply custom type conversion.
*/
final void fixEnum(Value[] row) { final void fixEnum(Value[] row) {
for (int i = 0, l = expressions.length; i < l; i++) { for (int i = 0, l = expressions.length; i < l; i++) {
TypeInfo type = expressions[i].getType(); TypeInfo type = expressions[i].getType();
......
...@@ -866,6 +866,9 @@ public class WebServer implements Service { ...@@ -866,6 +866,9 @@ public class WebServer implements Service {
adminPassword = total; adminPassword = total;
} }
/**
* true if admin password not configure, or admin password correct.
*/
boolean checkAdminPassword(String password) { boolean checkAdminPassword(String password) {
if (adminPassword == null) { if (adminPassword == null) {
return false; return false;
......
...@@ -70,6 +70,9 @@ public class DataType { ...@@ -70,6 +70,9 @@ public class DataType {
*/ */
private static final ArrayList<DataType> TYPES = new ArrayList<>(96); private static final ArrayList<DataType> TYPES = new ArrayList<>(96);
private static final HashMap<String, DataType> TYPES_BY_NAME = new HashMap<>(128); private static final HashMap<String, DataType> TYPES_BY_NAME = new HashMap<>(128);
/**
* Mapping from Value type numbers to DataType.
*/
static final DataType[] TYPES_BY_VALUE_TYPE = new DataType[Value.TYPE_COUNT]; static final DataType[] TYPES_BY_VALUE_TYPE = new DataType[Value.TYPE_COUNT];
/** /**
......
...@@ -31,6 +31,9 @@ public class ValueBytes extends Value { ...@@ -31,6 +31,9 @@ public class ValueBytes extends Value {
*/ */
protected byte[] value; protected byte[] value;
/**
* Associated TypeInfo.
*/
protected TypeInfo type; protected TypeInfo type;
/** /**
......
...@@ -18,7 +18,13 @@ import org.h2.util.StringUtils; ...@@ -18,7 +18,13 @@ import org.h2.util.StringUtils;
* client-server communication. * client-server communication.
*/ */
public class ValueEnumBase extends Value { public class ValueEnumBase extends Value {
/**
* Default precision.
*/
static final int PRECISION = 10; static final int PRECISION = 10;
/**
* Default display size.
*/
static final int DISPLAY_SIZE = 11; static final int DISPLAY_SIZE = 11;
private final String label; private final String label;
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论