Class: PgShrink::TableSanitizer
- Inherits:
-
Object
- Object
- PgShrink::TableSanitizer
- Defined in:
- lib/pg_shrink/table_sanitizer.rb
Instance Attribute Summary collapse
-
#table ⇒ Object
Returns the value of attribute table.
Instance Method Summary collapse
- #apply(hash) ⇒ Object
-
#initialize(table, opts, &block) ⇒ TableSanitizer
constructor
A new instance of TableSanitizer.
Constructor Details
#initialize(table, opts, &block) ⇒ TableSanitizer
Returns a new instance of TableSanitizer.
4 5 6 7 8 |
# File 'lib/pg_shrink/table_sanitizer.rb', line 4 def initialize(table, opts, &block) self.table = table @opts = opts # Currently not used, but who knows @block = block end |
Instance Attribute Details
#table ⇒ Object
Returns the value of attribute table.
3 4 5 |
# File 'lib/pg_shrink/table_sanitizer.rb', line 3 def table @table end |
Instance Method Details
#apply(hash) ⇒ Object
10 11 12 |
# File 'lib/pg_shrink/table_sanitizer.rb', line 10 def apply(hash) @block.call(hash) end |