Class: Api::ContractStatus
- Inherits:
-
Object
- Object
- Api::ContractStatus
- Defined in:
- lib/jamm/api/models/v1_contract_status.rb
Constant Summary collapse
- UNSPECIFIED =
'CONTRACT_STATUS_UNSPECIFIED'
- INITIAL =
'CONTRACT_STATUS_INITIAL'
- APPROVED =
'CONTRACT_STATUS_APPROVED'
- ACTIVATED =
'CONTRACT_STATUS_ACTIVATED'
- WAITING_EKYC =
'CONTRACT_STATUS_WAITING_EKYC'
- EXPIRED =
'CONTRACT_STATUS_EXPIRED'
- DEACTIVATED =
'CONTRACT_STATUS_DEACTIVATED'
- CANCELLED =
'CONTRACT_STATUS_CANCELLED'
- PENDING_CHARGE =
'CONTRACT_STATUS_PENDING_CHARGE'
Class Method Summary collapse
- .all_vars ⇒ Object
-
.build_from_hash(value) ⇒ String
Builds the enum from string.
Instance Method Summary collapse
-
#build_from_hash(value) ⇒ String
Builds the enum from string.
Class Method Details
.all_vars ⇒ Object
28 29 30 |
# File 'lib/jamm/api/models/v1_contract_status.rb', line 28 def self.all_vars @all_vars ||= [UNSPECIFIED, INITIAL, APPROVED, ACTIVATED, WAITING_EKYC, EXPIRED, DEACTIVATED, CANCELLED, PENDING_CHARGE].freeze end |
.build_from_hash(value) ⇒ String
Builds the enum from string
35 36 37 |
# File 'lib/jamm/api/models/v1_contract_status.rb', line 35 def self.build_from_hash(value) new.build_from_hash(value) end |
Instance Method Details
#build_from_hash(value) ⇒ String
Builds the enum from string
42 43 44 45 46 |
# File 'lib/jamm/api/models/v1_contract_status.rb', line 42 def build_from_hash(value) return value if ContractStatus.all_vars.include?(value) raise "Invalid ENUM value #{value} for class #ContractStatus" end |