Class: Plaid::Type3
- Inherits:
-
Object
- Object
- Plaid::Type3
- Defined in:
- lib/plaid/models/type3.rb
Overview
The type of the repayment plan.
Constant Summary collapse
- TYPE3 =
[ # TODO: Write general description for ENUM_EXTENDED_GRADUATED ENUM_EXTENDED_GRADUATED = 'extended graduated'.freeze, # TODO: Write general description for ENUM_EXTENDED_STANDARD ENUM_EXTENDED_STANDARD = 'extended standard'.freeze, # TODO: Write general description for GRADUATED GRADUATED = 'graduated'.freeze, # TODO: Write general description for ENUM_INCOMECONTINGENT_REPAYMENT ENUM_INCOMECONTINGENT_REPAYMENT = 'income-contingent repayment'.freeze, # TODO: Write general description for ENUM_INCOMEBASED_REPAYMENT ENUM_INCOMEBASED_REPAYMENT = 'income-based repayment'.freeze, # TODO: Write general description for INTERESTONLY INTERESTONLY = 'interest-only'.freeze, # TODO: Write general description for OTHER OTHER = 'other'.freeze, # TODO: Write general description for ENUM_PAY_AS_YOU_EARN ENUM_PAY_AS_YOU_EARN = 'pay as you earn'.freeze, # TODO: Write general description for ENUM_REVISED_PAY_AS_YOU_EARN ENUM_REVISED_PAY_AS_YOU_EARN = 'revised pay as you earn'.freeze, # TODO: Write general description for STANDARD STANDARD = 'standard'.freeze ].freeze
Class Method Summary collapse
Class Method Details
.from_value(value, default_value = ENUM_EXTENDED_GRADUATED) ⇒ Object
47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 |
# File 'lib/plaid/models/type3.rb', line 47 def self.from_value(value, default_value = ENUM_EXTENDED_GRADUATED) return default_value if value.nil? str = value.to_s.strip case str.downcase when 'enum_extended_graduated' then ENUM_EXTENDED_GRADUATED when 'enum_extended_standard' then ENUM_EXTENDED_STANDARD when 'graduated' then GRADUATED when 'enum_incomecontingent_repayment' then ENUM_INCOMECONTINGENT_REPAYMENT when 'enum_incomebased_repayment' then ENUM_INCOMEBASED_REPAYMENT when 'interestonly' then INTERESTONLY when 'other' then OTHER when 'enum_pay_as_you_earn' then ENUM_PAY_AS_YOU_EARN when 'enum_revised_pay_as_you_earn' then ENUM_REVISED_PAY_AS_YOU_EARN when 'standard' then STANDARD else default_value end end |
.validate(value) ⇒ Object
41 42 43 44 45 |
# File 'lib/plaid/models/type3.rb', line 41 def self.validate(value) return false if value.nil? true end |