Class: Itunes::Receipt::V2

Inherits:
Object
  • Object
show all
Includes:
Properties
Defined in:
lib/itunes/receipt/v2.rb

Constant Summary collapse

PROPERTY_LIST =
%w(receipt_type adam_id app_item_id bundle_id application_version download_id version_external_identifier
product_id receipt_creation_date request_date original_purchase_date original_application_version
transaction_id original_transaction_id quantity purchase_date expires_date web_order_line_item_id
is_trial_period)

Constants included from Properties

Properties::LIST

Instance Method Summary collapse

Methods included from Properties

included

Instance Method Details

#expired?Boolean

Returns:

  • (Boolean)


16
17
18
# File 'lib/itunes/receipt/v2.rb', line 16

def expired?
   self.expires_date < Time.now
end

#to_hObject



12
13
14
# File 'lib/itunes/receipt/v2.rb', line 12

def to_h
   YAML.load(data.to_yaml)
end