Module: Wice::WgEnumerable

Defined in:
lib/wice/wice_grid_core_ext.rb

Overview

:nodoc:

Class Method Summary collapse

Class Method Details

.all_items_are_of_class(enumerable, klass) ⇒ Object

Used to check the validity of :custom_filter parameter of column



94
95
96
97
# File 'lib/wice/wice_grid_core_ext.rb', line 94

def self.all_items_are_of_class(enumerable, klass)  #:nodoc:
  return false if enumerable.empty?
  enumerable.inject(true) { |memo, o| (o.is_a? klass) && memo }
end