| java.lang.Object com.caucho.db.store.Store com.caucho.db.table.Table
Table | public class Table extends Store (Code) | | Table format:
Block 0: allocation table
Block 1: fragment table
Block 2: table definition
0 - store data
1024 - table data
1024 - index pointers
2048 - CREATE text
Block 3: first data
|
Method Summary | |
public void | create() Creates the table. | public TableIterator | createTableIterator() | void | delete(Transaction xa, Block block, byte[] buffer, int rowOffset) | public Column | getAutoIncrementColumn() Returns the auto-increment column. | public Column | getColumn(String name) Returns the column for the given column name. | public int | getColumnIndex(String name) Returns the column index for the given column name. | final public Column[] | getColumns() | final public Constraint[] | getConstraints() Returns the table's constraints. | Row | getRow() | int | getRowEnd() | int | getRowLength() Returns the length of a row. | public long | insert(QueryContext queryContext, Transaction xa, ArrayList<Column> columns, ArrayList<Expr> values) Inserts a new row, returning the row address. | public void | insertRow(QueryContext queryContext, Transaction xa, ArrayList<Column> columns, ArrayList<Expr> values, Block block, int rowOffset) | public static Table | loadFromFile(Database db, String name) Loads the table from the file. | public long | nextAutoIncrement(QueryContext context) Returns the next auto-increment value. | public String | toString() |
INLINE_BLOB_SIZE | final public static int INLINE_BLOB_SIZE(Code) | | |
ROW_ALLOC | final public static byte ROW_ALLOC(Code) | | |
ROW_CLOCK_MIN | final public static long ROW_CLOCK_MIN(Code) | | |
ROW_MASK | final public static byte ROW_MASK(Code) | | |
ROW_VALID | final public static byte ROW_VALID(Code) | | |
getAutoIncrementColumn | public Column getAutoIncrementColumn()(Code) | | Returns the auto-increment column.
|
getColumn | public Column getColumn(String name)(Code) | | Returns the column for the given column name.
Parameters: name - the column name the column |
getColumnIndex | public int getColumnIndex(String name) throws SQLException(Code) | | Returns the column index for the given column name.
Parameters: name - the column name the column index. |
getConstraints | final public Constraint[] getConstraints()(Code) | | Returns the table's constraints.
|
getRowEnd | int getRowEnd()(Code) | | Returns the end of the row
|
getRowLength | int getRowLength()(Code) | | Returns the length of a row.
|
Methods inherited from com.caucho.db.store.Store | final public long addressToBlockId(long address)(Code)(Java Doc) public Block allocateBlock() throws IOException(Code)(Java Doc) public long allocateFragment(StoreTransaction xa) throws IOException(Code)(Java Doc) public Block allocateIndexBlock() throws IOException(Code)(Java Doc) public long allocateMiniFragment(StoreTransaction xa) throws IOException(Code)(Java Doc) public Block allocateRow() throws IOException(Code)(Java Doc) protected void assertStoreActive() throws IllegalStateException(Code)(Java Doc) public static long blockIdToAddress(long blockId)(Code)(Java Doc) public static long blockIdToAddress(long blockId, int offset)(Code)(Java Doc) public void close()(Code)(Java Doc) public static String codeToName(int code)(Code)(Java Doc) public static Store create(Path path) throws IOException, SQLException(Code)(Java Doc) public void create() throws IOException, SQLException(Code)(Java Doc) public void deleteFragment(StoreTransaction xa, long fragmentAddress) throws IOException(Code)(Java Doc) public void deleteMiniFragment(StoreTransaction xa, long fragmentAddress) throws IOException(Code)(Java Doc) public long firstBlock(long blockId, int type) throws IOException(Code)(Java Doc) public long firstFragment(long blockId) throws IOException(Code)(Java Doc) public long firstRow(long blockId) throws IOException(Code)(Java Doc) public void flush()(Code)(Java Doc) protected void freeBlock(long blockId) throws IOException(Code)(Java Doc) public byte[] getAllocationTable()(Code)(Java Doc) public long getBlockCount()(Code)(Java Doc) public BlockManager getBlockManager()(Code)(Java Doc) public long getFileSize()(Code)(Java Doc) public int getId()(Code)(Java Doc) public Lock getLock()(Code)(Java Doc) public String getName()(Code)(Java Doc) public long getTotalFragmentSize()(Code)(Java Doc) public void init() throws IOException(Code)(Java Doc) public boolean isClosed()(Code)(Java Doc) public boolean isFlushDirtyBlocksOnCommit()(Code)(Java Doc) public boolean isIndexBlock(long blockAddress)(Code)(Java Doc) public boolean isRowBlock(long blockAddress)(Code)(Java Doc) final public Block readBlock(long blockAddress) throws IOException(Code)(Java Doc) public int readBlock(long blockAddress, int blockOffset, byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public int readBlock(long blockAddress, int blockOffset, char[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void readBlock(long blockId, byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public long readBlockLong(long blockAddress, int offset) throws IOException(Code)(Java Doc) public int readFragment(long fragmentAddress, int fragmentOffset, byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public int readFragment(long fragmentAddress, int fragmentOffset, char[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public long readFragmentLong(long fragmentAddress, int fragmentOffset) throws IOException(Code)(Java Doc) public static long readLong(byte[] buffer, int offset)(Code)(Java Doc) public int readMiniFragment(long fragmentAddress, int fragmentOffset, byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public int readMiniFragment(long fragmentAddress, int fragmentOffset, char[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public long readMiniFragmentLong(long fragmentAddress, int fragmentOffset) throws IOException(Code)(Java Doc) public void remove() throws SQLException(Code)(Java Doc) public void setFlushDirtyBlocksOnCommit(boolean flushOnCommit)(Code)(Java Doc) public String toString()(Code)(Java Doc) protected void validateBlockId(long blockId) throws IllegalArgumentException, IllegalStateException(Code)(Java Doc) public void writeBlock(StoreTransaction xa, long blockAddress, int blockOffset, byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeBlock(StoreTransaction xa, long blockAddress, int blockOffset, char[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeBlock(long blockAddress, byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeBlockLong(StoreTransaction xa, long blockAddress, int offset, long value) throws IOException(Code)(Java Doc) public void writeFragment(StoreTransaction xa, long fragmentAddress, int fragmentOffset, byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeFragment(StoreTransaction xa, long fragmentAddress, int fragmentOffset, char[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeFragmentLong(StoreTransaction xa, long fragmentAddress, int fragmentOffset, long value) throws IOException(Code)(Java Doc) public static void writeLong(byte[] buffer, int offset, long v)(Code)(Java Doc) public void writeMiniFragment(StoreTransaction xa, long fragmentAddress, int fragmentOffset, byte[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeMiniFragment(StoreTransaction xa, long fragmentAddress, int fragmentOffset, char[] buffer, int offset, int length) throws IOException(Code)(Java Doc) public void writeMiniFragmentLong(StoreTransaction xa, long fragmentAddress, int fragmentOffset, long value) throws IOException(Code)(Java Doc)
|
|
|