public class StringArrayVTI
extends org.apache.derby.vti.StringColumnVTI
This is a concrete VTI which is prepopulated with rows which are just arrays of string columns.
| Modifier and Type | Class and Description |
|---|---|
static class |
StringArrayVTI.ConstructorException |
static class |
StringArrayVTI.GoodVTICosting |
static class |
StringArrayVTI.MissingConstructor |
static class |
StringArrayVTI.ZeroArgConstructorNotPublic |
| Modifier and Type | Field and Description |
|---|---|
private static java.lang.StringBuffer |
_callers |
private int |
_rowIdx |
private java.lang.String[][] |
_rows |
private static java.lang.String[] |
EXPECTED_STACK |
static double |
FAKE_INSTANTIATION_COST |
static double |
FAKE_ROW_COUNT |
| Constructor and Description |
|---|
StringArrayVTI(java.lang.String[] columnNames,
java.lang.String[][] rows) |
| Modifier and Type | Method and Description |
|---|---|
private java.sql.SQLException |
badStack(java.lang.String[] expected,
java.lang.String[] actual)
Complain that we don't like the stack.
|
void |
close() |
private java.lang.String |
deduceGetXXXCaller() |
private int |
findIndex(java.lang.String expectedMethod,
java.lang.String[] actualMethodNames)
Look for a method name on a stack and return its location as an
index into the stack.
|
protected java.lang.String |
getRawColumn(int columnNumber) |
static java.lang.String |
getXXXrecord()
This SQL function returns the list of getXXX() calls made to the last
StringArrayVTI.
|
private java.lang.String |
locateGetXXXCaller(java.lang.StackTraceElement[] stack)
Find the getXXX() method above us on the stack.
|
boolean |
next() |
protected java.sql.SQLException |
notImplemented(java.lang.String arg0) |
private java.lang.String[] |
squeezeMethodNames(java.lang.StackTraceElement[] stack)
Extract the names of methods on a stack.
|
private java.lang.String |
stringify(java.lang.Object[] raw)
Turn an array into a printable String.
|
findColumn, getAsciiStream, getBigDecimal, getBinaryStream, getBlob, getBoolean, getByte, getBytes, getClob, getColumnCount, getColumnName, getDate, getDouble, getFloat, getInt, getLong, getShort, getString, getTime, getTimestamp, wasNullgetBigDecimal, getBigDecimal, getBoolean, getByte, getBytes, getDate, getDouble, getFloat, getInt, getLong, getObject, getShort, getString, getTime, getTimestampclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetHoldability, getNCharacterStream, getNCharacterStream, getNClob, getNClob, getNString, getNString, getObject, getObject, getRowId, getRowId, getSQLXML, getSQLXML, isClosed, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateAsciiStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBinaryStream, updateBlob, updateBlob, updateBlob, updateBlob, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateCharacterStream, updateClob, updateClob, updateClob, updateClob, updateNCharacterStream, updateNCharacterStream, updateNCharacterStream, updateNCharacterStream, updateNClob, updateNClob, updateNClob, updateNClob, updateNClob, updateNClob, updateNString, updateNString, updateObject, updateObject, updateObject, updateObject, updateRowId, updateRowId, updateSQLXML, updateSQLXMLpublic static final double FAKE_ROW_COUNT
public static final double FAKE_INSTANTIATION_COST
private static final java.lang.String[] EXPECTED_STACK
private int _rowIdx
private java.lang.String[][] _rows
private static java.lang.StringBuffer _callers
public StringArrayVTI(java.lang.String[] columnNames,
java.lang.String[][] rows)
public static java.lang.String getXXXrecord()
This SQL function returns the list of getXXX() calls made to the last StringArrayVTI.
protected java.lang.String getRawColumn(int columnNumber)
throws java.sql.SQLException
getRawColumn in class org.apache.derby.vti.StringColumnVTIjava.sql.SQLExceptionprivate java.lang.String deduceGetXXXCaller()
throws java.sql.SQLException
java.sql.SQLExceptionpublic boolean next()
throws java.sql.SQLException
next in interface java.sql.ResultSetnext in class org.apache.derby.vti.VTITemplatejava.sql.SQLExceptionpublic void close()
throws java.sql.SQLException
close in interface java.lang.AutoCloseableclose in interface java.sql.ResultSetclose in class org.apache.derby.vti.VTITemplatejava.sql.SQLExceptionprivate java.lang.String locateGetXXXCaller(java.lang.StackTraceElement[] stack)
throws java.sql.SQLException
Find the getXXX() method above us on the stack. The stack looks like this:
java.sql.SQLExceptionprivate java.sql.SQLException badStack(java.lang.String[] expected,
java.lang.String[] actual)
Complain that we don't like the stack.
private int findIndex(java.lang.String expectedMethod,
java.lang.String[] actualMethodNames)
Look for a method name on a stack and return its location as an index into the stack. Returns -1 if the expected name is not found.
private java.lang.String[] squeezeMethodNames(java.lang.StackTraceElement[] stack)
Extract the names of methods on a stack.
private java.lang.String stringify(java.lang.Object[] raw)
Turn an array into a printable String.
protected java.sql.SQLException notImplemented(java.lang.String arg0)
Apache Derby V10.10 Internals - Copyright © 2004,2014 The Apache Software Foundation. All Rights Reserved.