class Crowbar::Client::Filter::Base

Base that provides methods shared between different filters

Attributes

options[RW]

Public Class Methods

new(options = {}) click to toggle source
# File lib/crowbar/client/filter/base.rb, line 26
def initialize(options = {})
  self.options = options
end

Public Instance Methods

process() click to toggle source
# File lib/crowbar/client/filter/base.rb, line 38
def process
  raise BadFilterError
end
result() click to toggle source
# File lib/crowbar/client/filter/base.rb, line 30
def result
  if options[:filter].present?
    process
  else
    options[:values]
  end
end