class Beaver::PaymentBank

PaymentBank Model.

Attributes

standard[RW]

The standard pricing model for payment banks to collect platform fees. @return [Standard]

type[RW]

The standard pricing model for payment banks to collect platform fees. @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.rb, line 32
def self.from_hash(hash)
  return nil unless hash

  # Extract variables from the hash.
  type = hash['type']
  standard = Standard.from_hash(hash['standard']) if hash['standard']

  # Create object from extracted values.
  PaymentBank.new(type,
                  standard)
end
names() click to toggle source

A mapping from model property names to API property names.

# File lib/beaver/models/payment_bank.rb, line 18
def self.names
  @_hash = {} if @_hash.nil?
  @_hash['standard'] = 'standard'
  @_hash['type'] = 'type'
  @_hash
end
new(type = nil, standard = nil) click to toggle source
# File lib/beaver/models/payment_bank.rb, line 25
def initialize(type = nil,
               standard = nil)
  @standard = standard
  @type = type
end