Class: Retab::EditWorkflowArtifact
- Inherits:
-
Types::BaseModel
- Object
- Types::BaseModel
- Retab::EditWorkflowArtifact
- Defined in:
- lib/retab/workflow_artifacts/edit_workflow_artifact.rb
Constant Summary collapse
- HASH_ATTRS =
{ id: :id, file: :file, model: :model, instructions: :instructions, config: :config, template_id: :template_id, output: :output, filled_document_ref: :filled_document_ref, usage: :usage, created_at: :created_at, operation: :operation }.freeze
Instance Attribute Summary collapse
-
#config ⇒ Object
Returns the value of attribute config.
-
#created_at ⇒ Object
Returns the value of attribute created_at.
-
#file ⇒ Object
Returns the value of attribute file.
-
#filled_document_ref ⇒ Object
Returns the value of attribute filled_document_ref.
-
#id ⇒ Object
Returns the value of attribute id.
-
#instructions ⇒ Object
Returns the value of attribute instructions.
-
#model ⇒ Object
Returns the value of attribute model.
-
#operation ⇒ Object
Returns the value of attribute operation.
-
#output ⇒ Object
Returns the value of attribute output.
-
#template_id ⇒ Object
Returns the value of attribute template_id.
-
#usage ⇒ Object
Returns the value of attribute usage.
Attributes inherited from Types::BaseModel
Instance Method Summary collapse
-
#initialize(json) ⇒ EditWorkflowArtifact
constructor
A new instance of EditWorkflowArtifact.
Methods inherited from Types::BaseModel
deep_symbolize, #inspect, normalize, #to_h, #to_json
Constructor Details
#initialize(json) ⇒ EditWorkflowArtifact
Returns a new instance of EditWorkflowArtifact.
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 36 def initialize(json) super() hash = self.class.normalize(json) @id = hash[:id] @file = hash[:file] ? Retab::FileRef.new(hash[:file]) : nil @model = hash[:model] @instructions = hash[:instructions] @config = hash[:config] ? Retab::EditConfig.new(hash[:config]) : nil @template_id = hash[:template_id] @output = hash[:output] ? Retab::EditResult.new(hash[:output]) : nil @filled_document_ref = hash[:filled_document_ref] ? Retab::FileRef.new(hash[:filled_document_ref]) : nil @usage = hash[:usage] ? Retab::RetabUsage.new(hash[:usage]) : nil @created_at = hash[:created_at] @operation = hash[:operation] end |
Instance Attribute Details
#config ⇒ Object
Returns the value of attribute config.
22 23 24 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 22 def config @config end |
#created_at ⇒ Object
Returns the value of attribute created_at.
22 23 24 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 22 def created_at @created_at end |
#file ⇒ Object
Returns the value of attribute file.
22 23 24 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 22 def file @file end |
#filled_document_ref ⇒ Object
Returns the value of attribute filled_document_ref.
22 23 24 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 22 def filled_document_ref @filled_document_ref end |
#id ⇒ Object
Returns the value of attribute id.
22 23 24 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 22 def id @id end |
#instructions ⇒ Object
Returns the value of attribute instructions.
22 23 24 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 22 def instructions @instructions end |
#model ⇒ Object
Returns the value of attribute model.
22 23 24 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 22 def model @model end |
#operation ⇒ Object
Returns the value of attribute operation.
22 23 24 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 22 def operation @operation end |
#output ⇒ Object
Returns the value of attribute output.
22 23 24 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 22 def output @output end |
#template_id ⇒ Object
Returns the value of attribute template_id.
22 23 24 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 22 def template_id @template_id end |
#usage ⇒ Object
Returns the value of attribute usage.
22 23 24 |
# File 'lib/retab/workflow_artifacts/edit_workflow_artifact.rb', line 22 def usage @usage end |