public class RowUtil
extends java.lang.Object
Note: this class is public so it may be used by Replication execution code. It is basically not public.
Modifier and Type | Field and Description |
---|---|
private static long |
rowCountBase
Row count base added for testing JDBC 4.2
|
Constructor and Description |
---|
RowUtil() |
Modifier and Type | Method and Description |
---|---|
static void |
copyCloneColumns(ExecRow to,
ExecRow from,
int count)
Clone an ExecRow's columns and place the coloned columns in another
ExecRow.
|
static void |
copyRefColumns(ExecRow setMe)
Empty columns -- i.e. make them refer to a java null.
|
static void |
copyRefColumns(ExecRow to,
ExecRow from)
Copy references for an ExecRow's columns to another ExecRow.
|
static void |
copyRefColumns(ExecRow to,
ExecRow from,
FormatableBitSet positions)
Copy references for an ExecRow's columns to another ExecRow.
|
static void |
copyRefColumns(ExecRow to,
ExecRow from,
int count)
Copy references for an ExecRow's columns to another ExecRow.
|
static void |
copyRefColumns(ExecRow to,
ExecRow from,
int[] positions)
Copy references for an ExecRow's columns to another ExecRow.
|
static void |
copyRefColumns(ExecRow to,
ExecRow from,
int start,
int count)
Copy references for an ExecRow's columns to another ExecRow.
|
static void |
copyRefColumns(ExecRow to,
int toStart,
ExecRow from,
int fromStart,
int count)
Copy references for an ExecRow's columns to another ExecRow.
|
static ExecIndexRow |
getEmptyIndexRow(int columnCount,
LanguageConnectionContext lcc)
Get an empty ExecIndexRow.
|
static ExecRow |
getEmptyValueRow(int columnCount,
LanguageConnectionContext lcc)
Get an empty ExecRow.
|
static long |
getRowCountBase()
Retrieve the row count base
|
static boolean |
inAscendingOrder(int[] colMap) |
static java.lang.String |
intArrayToString(int[] colMap)
intArrayToString
|
static void |
setRowCountBase(long newBase)
Debug method used to test the setLargeMaxRows() method added by JDBC 4.2.
|
static FormatableBitSet |
shift(FormatableBitSet bitSet,
int n)
Shift a FormatableBitSet N bits toward the zero end.
|
static java.lang.String |
toString(ExecRow row)
toString
|
static java.lang.String |
toString(ExecRow row,
int[] positions)
toString
|
static java.lang.String |
toString(ExecRow row,
int startPoint,
int endPoint)
toString
|
static java.lang.String |
toString(java.lang.Object[] objs)
toString
|
static java.lang.String |
toString(java.lang.Object[] objs,
int[] positions)
toString
|
static java.lang.String |
toString(java.lang.Object[] objs,
int startPoint,
int endPoint)
toString
|
private static long rowCountBase
public static void setRowCountBase(long newBase)
public static long getRowCountBase()
public static ExecRow getEmptyValueRow(int columnCount, LanguageConnectionContext lcc)
columnCount
- the number of columns in the row.public static ExecIndexRow getEmptyIndexRow(int columnCount, LanguageConnectionContext lcc)
columnCount
- the number of columns in the row.public static void copyCloneColumns(ExecRow to, ExecRow from, int count)
to
- Place the cloned columns here.from
- Get the columns to clone here.count
- Clone this number of columns.public static void copyRefColumns(ExecRow to, ExecRow from)
to
- Place the column references here.from
- Get the column references from here.public static void copyRefColumns(ExecRow to, ExecRow from, int count) throws StandardException
to
- Place the column references here.from
- Get the column references from here.count
- Copy this number of column references.StandardException
public static void copyRefColumns(ExecRow to, ExecRow from, int start, int count) throws StandardException
to
- Place the column references here.from
- Get the column references from here.start
- The 0 based index of the first column to copy.count
- Copy this number of column references.StandardException
public static void copyRefColumns(ExecRow to, int toStart, ExecRow from, int fromStart, int count) throws StandardException
to
- Place the column references here.toStart
- The 0-based index of the first column to replace.from
- Get the column references from here.fromStart
- The 0 based index of the first column to copy.count
- Copy this number of column references.StandardException
public static void copyRefColumns(ExecRow to, ExecRow from, int[] positions) throws StandardException
to
- Place the column references here.from
- Get the column references from here.positions
- array of 1-based column ids to copy from "from" to "to"StandardException
public static void copyRefColumns(ExecRow to, ExecRow from, FormatableBitSet positions) throws StandardException
to
- Place the column references here. Sparse arrayfrom
- Get the column references from here. Compact arraypositions
- array of 1-based column ids to copy from "from" to "to"StandardException
public static void copyRefColumns(ExecRow setMe) throws StandardException
This is useful to remove dangling references to a column.
setMe
- Set columns in this storable to be empty.StandardException
public static java.lang.String toString(ExecRow row)
row
- the rowpublic static java.lang.String toString(java.lang.Object[] objs)
objs
- the row arraypublic static java.lang.String toString(ExecRow row, int startPoint, int endPoint)
row
- the rowstartPoint
- 0 based start point in row array, inclusiveendPoint
- 0 based end point in row array, inclusivepublic static java.lang.String toString(java.lang.Object[] objs, int startPoint, int endPoint)
objs
- the row arraystartPoint
- 0 based start point in row array, inclusiveendPoint
- 0 based end point in row array, inclusivepublic static java.lang.String toString(ExecRow row, int[] positions)
row
- the rowpositions
- 1 based array of positionspublic static java.lang.String toString(java.lang.Object[] objs, int[] positions)
objs
- the row arraypositions
- 1 based array of positionspublic static java.lang.String intArrayToString(int[] colMap)
colMap
- the int arraypublic static boolean inAscendingOrder(int[] colMap)
public static FormatableBitSet shift(FormatableBitSet bitSet, int n)
bitSet
- the bit setn
- the number of bits to shiftApache Derby V10.13 Internals - Copyright © 2004,2016 The Apache Software Foundation. All Rights Reserved.