Package | Description |
---|---|
edu.berkeley.cs186.database | |
edu.berkeley.cs186.database.query | |
edu.berkeley.cs186.database.table |
Modifier and Type | Method and Description |
---|---|
RecordID |
Database.Transaction.addRecord(String tableName,
List<DataBox> values) |
void |
Database.createTable(Schema s,
String tableName)
Create a new table in this database.
|
void |
Database.Transaction.createTempTable(Schema schema,
String tempTableName)
Create a temporary table within this transaction.
|
void |
Database.Transaction.deleteRecord(String tableName,
RecordID rid) |
Schema |
Database.Transaction.getFullyQualifiedSchema(String tableName) |
Record |
Database.Transaction.getRecord(String tableName,
RecordID rid) |
Iterator<Record> |
Database.Transaction.getRecordIterator(String tableName) |
Schema |
Database.Transaction.getSchema(String tableName) |
QueryPlan |
Database.Transaction.query(String tableName)
Allows the user to query a table.
|
void |
Database.Transaction.queryAs(String tableName,
String alias)
Allows the user to provide an alias for a particular table.
|
void |
Database.Transaction.updateRecord(String tableName,
List<DataBox> values,
RecordID rid) |
Constructor and Description |
---|
Database(String fileDir)
Creates a new database.
|
Modifier and Type | Method and Description |
---|---|
Iterator<Record> |
SelectOperator.execute() |
Iterator<Record> |
SequentialScanOperator.execute() |
Iterator<Record> |
ProjectOperator.execute()
Joins tuples from leftSource with tuples from rightSource based on whether the values in column
leftColumnName are equal to tha values in column rightColumnName.
|
Iterator<Record> |
QueryPlan.execute()
Generates a naïve QueryPlan in which all joins are at the bottom of the DAG followed by all where
predicates, an optional group by operator, and a set of selects (in that order).
|
abstract Iterator<Record> |
QueryOperator.execute() |
Iterator<Record> |
JoinOperator.execute()
Joins tuples from leftSource and rightSource and returns an iterator of records.
|
Iterator<Record> |
GroupByOperator.execute()
Read input tuples from source, group by groupByColumn, and return an iterator.
|
Constructor and Description |
---|
SequentialScanOperator(Database.Transaction transaction,
String tableName)
Creates a new SequentialScanOperator that provides an iterator on all tuples in a table.
|
Modifier and Type | Method and Description |
---|---|
RecordID |
Table.addRecord(List<DataBox> values)
Adds a new record to this table.
|
Record |
Table.deleteRecord(RecordID rid)
Deletes the record specified by rid from the table.
|
Record |
Table.getRecord(RecordID rid)
Retrieves a record from the table.
|
Record |
Table.updateRecord(List<DataBox> values,
RecordID rid)
Updates an existing record with new values and returns the old version of the record.
|
Copyright © 2017. All rights reserved.