Class: Amex::LoyaltyProgramme

Inherits:
Object
  • Object
show all
Defined in:
lib/amex/loyalty_programme.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, balance) ⇒ Amex::LoyaltyProgramme

Generates an Amex::LoyaltyProgramme object from a programme name and balance, grabbed from the XML

Parameters:

  • name (String)

    The name of the reward programme

  • balance (Fixnum)

    The balance of the reward programme


13
14
15
16
# File 'lib/amex/loyalty_programme.rb', line 13

def initialize(name, balance)
  @name = name
  @balance = balance
end

Instance Attribute Details

#balanceObject

Returns the value of attribute balance


3
4
5
# File 'lib/amex/loyalty_programme.rb', line 3

def balance
  @balance
end

#nameObject

Returns the value of attribute name


3
4
5
# File 'lib/amex/loyalty_programme.rb', line 3

def name
  @name
end