Class: Io::Flow::V0::Models::PromotionUndefinedType

Inherits:
Promotion
  • Object
show all
Defined in:
lib/flow_commerce/flow_api_v0_client.rb

Instance Attribute Summary collapse

Attributes inherited from Promotion

#discriminator

Instance Method Summary collapse

Methods inherited from Promotion

from_json

Constructor Details

#initialize(incoming = {}) ⇒ PromotionUndefinedType

Returns a new instance of PromotionUndefinedType.



14568
14569
14570
14571
14572
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14568

def initialize(incoming={})
  super(:discriminator => 'undefined_type')
  opts = HttpClient::Helper.symbolize_keys(incoming)
  @name = HttpClient::Preconditions.assert_class('name', opts.delete(:discriminator), String)
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name.



14566
14567
14568
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14566

def name
  @name
end

Instance Method Details

#copy(incoming = {}) ⇒ Object



14578
14579
14580
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14578

def copy(incoming={})
  raise 'Operation not supported for undefined type'
end

#subtype_to_hashObject



14574
14575
14576
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14574

def subtype_to_hash
  raise 'Unable to serialize undefined type to json'
end

#to_hashObject



14582
14583
14584
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 14582

def to_hash
  raise 'Operation not supported for undefined type'
end