Class: Moov::Models::Components::Wallet
- Inherits:
-
Object
- Object
- Moov::Models::Components::Wallet
- Extended by:
- T::Sig
- Includes:
- Crystalline::MetadataFields
- Defined in:
- lib/moov/models/components/wallet.rb
Overview
A Moov wallet to store funds for transfers.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(wallet_id:, available_balance:, partner_account_id:, name:, status:, wallet_type:, description:, created_on:, metadata: nil, closed_on: nil) ⇒ Wallet
constructor
A new instance of Wallet.
Methods included from Crystalline::MetadataFields
#field, #fields, included, #marshal_single, #to_dict, #to_json
Constructor Details
#initialize(wallet_id:, available_balance:, partner_account_id:, name:, status:, wallet_type:, description:, created_on:, metadata: nil, closed_on: nil) ⇒ Wallet
Returns a new instance of Wallet.
41 42 43 44 45 46 47 48 49 50 51 52 |
# File 'lib/moov/models/components/wallet.rb', line 41 def initialize(wallet_id:, available_balance:, partner_account_id:, name:, status:, wallet_type:, description:, created_on:, metadata: nil, closed_on: nil) @wallet_id = wallet_id @available_balance = available_balance @partner_account_id = partner_account_id @name = name @status = status @wallet_type = wallet_type @description = description @created_on = created_on @metadata = @closed_on = closed_on end |
Instance Method Details
#==(other) ⇒ Object
55 56 57 58 59 60 61 62 63 64 65 66 67 68 |
# File 'lib/moov/models/components/wallet.rb', line 55 def ==(other) return false unless other.is_a? self.class return false unless @wallet_id == other.wallet_id return false unless @available_balance == other.available_balance return false unless @partner_account_id == other.partner_account_id return false unless @name == other.name return false unless @status == other.status return false unless @wallet_type == other.wallet_type return false unless @description == other.description return false unless @created_on == other.created_on return false unless @metadata == other. return false unless @closed_on == other.closed_on true end |