Class: ThePlaidApi::AssetEmployerSponsoredIndicator
- Inherits:
-
Object
- Object
- ThePlaidApi::AssetEmployerSponsoredIndicator
- Defined in:
- lib/the_plaid_api/models/asset_employer_sponsored_indicator.rb
Overview
Whether the account is employer sponsored retirement account or not (e.g., 401K, 403b, 457, thrift savings plan)
Constant Summary collapse
- ASSET_EMPLOYER_SPONSORED_INDICATOR =
[ # TODO: Write general description for ENUM_TRUE ENUM_TRUE = 'true'.freeze, # TODO: Write general description for ENUM_FALSE ENUM_FALSE = 'false'.freeze ].freeze
Class Method Summary collapse
Class Method Details
.from_value(value, default_value = ENUM_TRUE) ⇒ Object
24 25 26 27 28 29 30 31 32 33 34 35 |
# File 'lib/the_plaid_api/models/asset_employer_sponsored_indicator.rb', line 24 def self.from_value(value, default_value = ENUM_TRUE) return default_value if value.nil? str = value.to_s.strip case str.downcase when 'enum_true' then ENUM_TRUE when 'enum_false' then ENUM_FALSE else default_value end end |
.validate(value) ⇒ Object
18 19 20 21 22 |
# File 'lib/the_plaid_api/models/asset_employer_sponsored_indicator.rb', line 18 def self.validate(value) return false if value.nil? ASSET_EMPLOYER_SPONSORED_INDICATOR.include?(value) end |