Class: Balanced::Reversal

Inherits:
Object
  • Object
show all
Includes:
Resource
Defined in:
lib/balanced/resources/reversal.rb

Overview

A Reversal represents a reversal of funds from a Credit. A Credit can have many Reversals associated with it up to the total amount of the original Reversal. Funds are returned to your Marketplace’s Merchant Account proportional to the amount of the Reversal.

Instance Attribute Summary

Attributes included from Resource

#attributes

Instance Method Summary collapse

Methods included from Resource

#copy_from, #destroy, #find, included, #method_missing, #reload, #sanitize, #save, #unstore, #warn_on_positional

Constructor Details

#initialize(attributes = {}) ⇒ Reversal

Returns a new instance of Reversal.



10
11
12
13
14
15
16
# File 'lib/balanced/resources/reversal.rb', line 10

def initialize attributes = {}
  Balanced::Utils.stringify_keys! attributes
  unless attributes.has_key? 'uri'
    attributes['uri'] = self.class.uri
  end
  super attributes
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Balanced::Resource