class Io::Flow::V0::Models::ExclusionRuleForm
Attributes
description[R]
q[R]
regions[R]
Public Class Methods
new(incoming={})
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 41278 def initialize(incoming={}) opts = HttpClient::Helper.symbolize_keys(incoming) HttpClient::Preconditions.require_keys(opts, [:q, :regions], 'ExclusionRuleForm') @q = HttpClient::Preconditions.assert_class('q', opts.delete(:q), String) @regions = HttpClient::Preconditions.assert_class('regions', opts.delete(:regions), Array).map { |v| HttpClient::Preconditions.assert_class('regions', v, String) } @description = (x = opts.delete(:description); x.nil? ? nil : HttpClient::Preconditions.assert_class('description', x, String)) end
Public Instance Methods
copy(incoming={})
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 41290 def copy(incoming={}) ExclusionRuleForm.new(to_hash.merge(HttpClient::Helper.symbolize_keys(incoming))) end
to_hash()
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 41294 def to_hash { :q => q, :regions => regions, :description => description } end
to_json()
click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 41286 def to_json JSON.dump(to_hash) end