Class: ThePlaidApi::RiskSignalDocumentStatus
- Inherits:
-
Object
- Object
- ThePlaidApi::RiskSignalDocumentStatus
- Defined in:
- lib/the_plaid_api/models/risk_signal_document_status.rb
Overview
Status of a document for risk signal analysis
Constant Summary collapse
- RISK_SIGNAL_DOCUMENT_STATUS =
[ # TODO: Write general description for PROCESSING PROCESSING = 'PROCESSING'.freeze, # TODO: Write general description for PROCESSING_COMPLETE PROCESSING_COMPLETE = 'PROCESSING_COMPLETE'.freeze, # TODO: Write general description for PROCESSING_ERROR PROCESSING_ERROR = 'PROCESSING_ERROR'.freeze, # TODO: Write general description for PASSWORD_PROTECTED PASSWORD_PROTECTED = 'PASSWORD_PROTECTED'.freeze, # TODO: Write general description for VIRUS_DETECTED VIRUS_DETECTED = 'VIRUS_DETECTED'.freeze ].freeze
Class Method Summary collapse
Class Method Details
.from_value(value, default_value = PROCESSING) ⇒ Object
32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 |
# File 'lib/the_plaid_api/models/risk_signal_document_status.rb', line 32 def self.from_value(value, default_value = PROCESSING) return default_value if value.nil? str = value.to_s.strip case str.downcase when 'processing' then PROCESSING when 'processing_complete' then PROCESSING_COMPLETE when 'processing_error' then PROCESSING_ERROR when 'password_protected' then PASSWORD_PROTECTED when 'virus_detected' then VIRUS_DETECTED else default_value end end |
.validate(value) ⇒ Object
26 27 28 29 30 |
# File 'lib/the_plaid_api/models/risk_signal_document_status.rb', line 26 def self.validate(value) return false if value.nil? RISK_SIGNAL_DOCUMENT_STATUS.include?(value) end |