Sha256: 201b9afd875255372d8a7a83b97211e1c1ed3f3955d1816f69dd69307959e676

Contents?: true

Size: 558 Bytes

Versions: 9

Compression:

Stored size: 558 Bytes

Contents

module Dyna
  module Filterable
    def should_skip(table_name)
      if @options.table_names
        unless @options.table_names.include?(table_name)
          log(:debug, "skip table(with tables_names option) #{table_name}", false)
          return true
        end
      end

      if @options.exclude_table_names
        if @options.exclude_table_names.any? {|regex| table_name =~ regex}
          log(:debug, "skip table(with exclude_tables_names option) #{table_name}", false)
          return true
        end
      end

      false
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
dyna-0.2.3 lib/dyna/filterable.rb
dyna-0.2.2 lib/dyna/filterable.rb
dyna-0.2.1 lib/dyna/filterable.rb
dyna-0.2.1.beta2 lib/dyna/filterable.rb
dyna-0.2.1.beta1 lib/dyna/filterable.rb
dyna-0.2.0 lib/dyna/filterable.rb
dyna-0.1.9 lib/dyna/filterable.rb
dyna-0.1.8 lib/dyna/filterable.rb
dyna-0.1.7 lib/dyna/filterable.rb