class Ingenico::Connect::SDK::Domain::Mandates::MandatePersonalInformation

@attr [Ingenico::Connect::SDK::Domain::Mandates::MandatePersonalName] name @attr [String] title

Attributes

name[RW]
title[RW]

Public Instance Methods

from_hash(hash) click to toggle source
# File lib/ingenico/connect/sdk/domain/mandates/mandate_personal_information.rb, line 28
def from_hash(hash)
  super
  if hash.has_key? 'name'
    raise TypeError, "value '%s' is not a Hash" % [hash['name']] unless hash['name'].is_a? Hash
    @name = Ingenico::Connect::SDK::Domain::Mandates::MandatePersonalName.new_from_hash(hash['name'])
  end
  if hash.has_key? 'title'
    @title = hash['title']
  end
end
to_h() click to toggle source

@return (Hash)

Calls superclass method Ingenico::Connect::SDK::DataObject#to_h
# File lib/ingenico/connect/sdk/domain/mandates/mandate_personal_information.rb, line 21
def to_h
  hash = super
  hash['name'] = @name.to_h unless @name.nil?
  hash['title'] = @title unless @title.nil?
  hash
end