module HaystackRuby::Types::Bin

Public Instance Methods

set_fields(str_value) click to toggle source
# File lib/haystack_ruby/types/bin.rb, line 4
def set_fields str_value
  @haystack_type = 'Bin'
  match = /\Ab:(.*)\z/.match str_value
  raise HaystackRuby::Error, "invalid HaystackRuby::Types::Bin: #{str_value}" if match.nil?
  # Value is mime type
  @value = match[1]
end