class Beaver::CreditCard4
Credit card structure to be used for updating credit card information.
Attributes
card_on_file[RW]
TODO: Write general description for this method @return [Boolean]
recurring[RW]
TODO: Write general description for this method @return [Boolean]
Public Class Methods
from_hash(hash)
click to toggle source
Creates an instance of the object from a hash.
# File lib/beaver/models/credit_card4.rb, line 32 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. card_on_file = hash['card_on_file'] recurring = hash['recurring'] # Create object from extracted values. CreditCard4.new(card_on_file, recurring) end
names()
click to toggle source
A mapping from model property names to API property names.
# File lib/beaver/models/credit_card4.rb, line 18 def self.names @_hash = {} if @_hash.nil? @_hash['card_on_file'] = 'card_on_file' @_hash['recurring'] = 'recurring' @_hash end
new(card_on_file = nil, recurring = nil)
click to toggle source
# File lib/beaver/models/credit_card4.rb, line 25 def initialize(card_on_file = nil, recurring = nil) @card_on_file = card_on_file @recurring = recurring end