Method: Wice::GridOutputBuffer#filter_for

Defined in:
lib/grid_output_buffer.rb

#filter_for(detach_with_id) ⇒ Object Also known as: []

Raises:



35
36
37
38
39
40
41
42
43
44
45
46
47
# File 'lib/grid_output_buffer.rb', line 35

def filter_for detach_with_id
  unless @filters.has_key? detach_with_id
    if @return_empty_strings_for_nonexistent_filters
      return ''
    else
      raise  WiceGridException.new("No filter with Detached ID '#{detach_with_id}'!")
    end
  end
  raise  WiceGridException.new("Filter with Detached ID '#{detach_with_id}' has already been requested once! There cannot be two instances of the same filter on one page") if @filters[detach_with_id] == false
  res = @filters[detach_with_id]
  @filters[detach_with_id] = false
  return res
end