Class: ThePlaidApi::Type3
- Inherits:
-
Object
- Object
- ThePlaidApi::Type3
- Defined in:
- lib/the_plaid_api/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 ENUM_INCOMESENSITIVE_REPAYMENT ENUM_INCOMESENSITIVE_REPAYMENT = 'income-sensitive 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, # TODO: Write general description for ENUM_SAVING_ON_A_VALUABLE_EDUCATION ENUM_SAVING_ON_A_VALUABLE_EDUCATION = 'saving on a valuable education'.freeze ].freeze
Class Method Summary collapse
Class Method Details
.from_value(value, default_value = ENUM_EXTENDED_GRADUATED) ⇒ Object
53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 |
# File 'lib/the_plaid_api/models/type3.rb', line 53 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 'enum_incomesensitive_repayment' then ENUM_INCOMESENSITIVE_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 when 'enum_saving_on_a_valuable_education' then ENUM_SAVING_ON_A_VALUABLE_EDUCATION else default_value end end |
.validate(value) ⇒ Object
47 48 49 50 51 |
# File 'lib/the_plaid_api/models/type3.rb', line 47 def self.validate(value) return false if value.nil? TYPE3.include?(value) end |