class Beaver::PaymentBankUsReq

PaymentBankUsReq Model.

Attributes

account_holder[RW]

TODO: Write general description for this method @return [HolderReq]

account_number[RW]

TODO: Write general description for this method @return [String]

account_type[RW]

TODO: Write general description for this method @return [AccountTypeEnum]

routing_number[RW]

TODO: Write general description for this method @return [String]

Public Class Methods

from_hash(hash) click to toggle source

Creates an instance of the object from a hash.

# File lib/beaver/models/payment_bank_us_req.rb, line 46
def self.from_hash(hash)
  return nil unless hash

  # Extract variables from the hash.
  account_holder = HolderReq.from_hash(hash['account_holder']) if
    hash['account_holder']
  account_number = hash['account_number']
  account_type = hash['account_type']
  routing_number = hash['routing_number']

  # Create object from extracted values.
  PaymentBankUsReq.new(account_holder,
                       account_number,
                       account_type,
                       routing_number)
end
names() click to toggle source

A mapping from model property names to API property names.

# File lib/beaver/models/payment_bank_us_req.rb, line 26
def self.names
  @_hash = {} if @_hash.nil?
  @_hash['account_holder'] = 'account_holder'
  @_hash['account_number'] = 'account_number'
  @_hash['account_type'] = 'account_type'
  @_hash['routing_number'] = 'routing_number'
  @_hash
end
new(account_holder = nil, account_number = nil, account_type = nil, routing_number = nil) click to toggle source
# File lib/beaver/models/payment_bank_us_req.rb, line 35
def initialize(account_holder = nil,
               account_number = nil,
               account_type = nil,
               routing_number = nil)
  @account_holder = account_holder
  @account_number = account_number
  @account_type = account_type
  @routing_number = routing_number
end