MCPcopy Create free account
hub / github.com/1345414527/MIT6.830 / Insert

Method Insert

src/java/simpledb/execution/Insert.java:41–50  ·  view source on GitHub ↗

Constructor. @param t The transaction running the insert. @param child The child operator from which to read tuples to be inserted. @param tableId The table in which to insert tuples. @throws DbException if TupleDesc of child differs from table into whic

(TransactionId t, OpIterator child, int tableId)

Source from the content-addressed store, hash-verified

39 * insert.
40 */
41 public Insert(TransactionId t, OpIterator child, int tableId)
42 throws DbException {
43 // some code goes here
44 this.t = t;
45 this.child =child;
46 this.tableId = tableId;
47 if(!child.getTupleDesc().equals(Database.getCatalog().getTupleDesc(tableId))){
48 throw new DbException("insert tupleDesc not equal.");
49 }
50 }
51
52 public TupleDesc getTupleDesc() {
53 // some code goes here

Callers

nothing calls this directly

Calls 3

getCatalogMethod · 0.95
equalsMethod · 0.65
getTupleDescMethod · 0.65

Tested by

no test coverage detected