Module: DbAgile::Contract::Data::TransactionDriven
- Included in:
- Utils::Full
- Defined in:
- lib/dbagile/contract/data/transaction_driven.rb
Overview
Transaction driven methods of the contract
Instance Method Summary collapse
-
#delete(transaction, table_name, proj = {}) ⇒ Object
Delete all tuples whose projection equal proj inside a given table.
-
#direct_sql(transaction, sql) ⇒ ...
Send SQL directly to the database SQL server.
-
#insert(transaction, table_name, record) ⇒ Hash
Inserts a tuple inside a given table.
-
#update(transaction, table_name, update, proj = {}) ⇒ Hash
Updates all tuples whose projection equal proj with values given by update inside a given table.
Instance Method Details
#delete(transaction, table_name, proj = {}) ⇒ Object
Delete all tuples whose projection equal proj inside a given table
54 55 56 |
# File 'lib/dbagile/contract/data/transaction_driven.rb', line 54 def delete(transaction, table_name, proj = {}) Kernel.raise NotImplementedError end |
#direct_sql(transaction, sql) ⇒ ...
Send SQL directly to the database SQL server.
Returned result is left opened to adapters.
67 68 69 |
# File 'lib/dbagile/contract/data/transaction_driven.rb', line 67 def direct_sql(transaction, sql) Kernel.raise NotImplementedError end |
#insert(transaction, table_name, record) ⇒ Hash
Inserts a tuple inside a given table
21 22 23 |
# File 'lib/dbagile/contract/data/transaction_driven.rb', line 21 def insert(transaction, table_name, record) Kernel.raise NotImplementedError end |
#update(transaction, table_name, update, proj = {}) ⇒ Hash
Updates all tuples whose projection equal proj with values given by update inside a given table
39 40 41 |
# File 'lib/dbagile/contract/data/transaction_driven.rb', line 39 def update(transaction, table_name, update, proj = {}) Kernel.raise NotImplementedError end |