Class: SmartRecruiters::ConsentStatus
- Inherits:
-
Object
- Object
- SmartRecruiters::ConsentStatus
- Defined in:
- lib/smart_recruiters/models/consent_status.rb
Constant Summary collapse
- REQUIRED =
'REQUIRED'.freeze
- PENDING =
'PENDING'.freeze
- ACQUIRED =
'ACQUIRED'.freeze
Instance Method Summary collapse
-
#build_from_hash(value) ⇒ String
Builds the enum from string.
Instance Method Details
#build_from_hash(value) ⇒ String
Builds the enum from string
14 15 16 17 18 |
# File 'lib/smart_recruiters/models/consent_status.rb', line 14 def build_from_hash(value) constantValues = ConsentStatus.constants.select { |c| ConsentStatus::const_get(c) == value } raise "Invalid ENUM value #{value} for class #ConsentStatus" if constantValues.empty? value end |