class Beaver::PayoutsRequest
PayoutsRequest
Model.
Attributes
custom_data[RW]
TODO: Write general description for this method @return [Object]
rbits[RW]
TODO: Write general description for this method @return [List of EmbeddedRbit]
Public Class Methods
from_hash(hash)
click to toggle source
Creates an instance of the object from a hash.
# File lib/beaver/models/payouts_request.rb, line 32 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. custom_data = hash['custom_data'] # Parameter is an array, so we need to iterate through it rbits = nil unless hash['rbits'].nil? rbits = [] hash['rbits'].each do |structure| rbits << (EmbeddedRbit.from_hash(structure) if structure) end end # Create object from extracted values. PayoutsRequest.new(custom_data, rbits) end
names()
click to toggle source
A mapping from model property names to API property names.
# File lib/beaver/models/payouts_request.rb, line 18 def self.names @_hash = {} if @_hash.nil? @_hash['custom_data'] = 'custom_data' @_hash['rbits'] = 'rbits' @_hash end
new(custom_data = nil, rbits = nil)
click to toggle source
# File lib/beaver/models/payouts_request.rb, line 25 def initialize(custom_data = nil, rbits = nil) @custom_data = custom_data @rbits = rbits end