Class: Remitmd::A2AArtifact
- Inherits:
-
Object
- Object
- Remitmd::A2AArtifact
- Defined in:
- lib/remitmd/a2a.rb
Overview
An artifact returned by an A2A task.
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#parts ⇒ Object
readonly
Returns the value of attribute parts.
Instance Method Summary collapse
-
#initialize(data) ⇒ A2AArtifact
constructor
A new instance of A2AArtifact.
Constructor Details
#initialize(data) ⇒ A2AArtifact
Returns a new instance of A2AArtifact.
78 79 80 81 82 83 |
# File 'lib/remitmd/a2a.rb', line 78 def initialize(data) @name = data["name"] @parts = (data["parts"] || []).map do |p| A2AArtifactPart.new(kind: p["kind"].to_s, data: p["data"] || {}) end end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name.
76 77 78 |
# File 'lib/remitmd/a2a.rb', line 76 def name @name end |
#parts ⇒ Object (readonly)
Returns the value of attribute parts.
76 77 78 |
# File 'lib/remitmd/a2a.rb', line 76 def parts @parts end |