module AuthorizeNet::Model
Provides some basic methods used by the various model classes.
Public Class Methods
new(fields = {})
click to toggle source
The constructor for models. Takes any of the supported attributes as key/value pairs.
# File lib/authorize_net/authorize_net.rb, line 136 def initialize(fields = {}) fields.each do |k, v| method_name = (k.to_s + '=').to_sym send(method_name, v) if respond_to?(method_name) end end
Public Instance Methods
to_a()
click to toggle source
# File lib/authorize_net/authorize_net.rb, line 143 def to_a [self] end