Module: Cassie::Statements::Statement::Deleting::ClassMethods

Included in:
Cassie::Statements::Statement::Deleting
Defined in:
lib/cassie/statements/statement/deleting.rb

Instance Method Summary collapse

Instance Method Details

#column(identifier) ⇒ Object

Add a specific column to tombstone by this statement



40
41
42
43
44
# File 'lib/cassie/statements/statement/deleting.rb', line 40

def column(identifier)
  # @todo replace with Selection
  # Module and aliases?
  columns << identifier.to_s
end

#columnsArray<String>

The columns to be tombstoned from this statement



48
49
50
# File 'lib/cassie/statements/statement/deleting.rb', line 48

def columns
  @columns ||= []
end

#delete_from(table) {|_self| ... } ⇒ void

This method returns an undefined value.

DSL to set the statement type and table for deleting

Yields:

  • (_self)

Yield Parameters:



31
32
33
34
35
36
# File 'lib/cassie/statements/statement/deleting.rb', line 31

def delete_from(table)
  self.table = table
  self.type = :delete

  yield(self) if block_given?
end