class SushiNet::StoreItem

  attr_accessor :title, :subtitle, :description, :price

  def initialize(title, subtitle, description, price)
    @title = title
    @subtitle = subtitle
    @description = description
    @price = price
  end

  def matches(search_string)
    return @title =~ Regexp.new(Regexp.quote(search_string), true) ||
           @description =~ Regexp.new(Regexp.quote(search_string), true)
  end

end # class SushiNet::StoreItem

