Class: VectorMCP::Transport::HttpStream::EventStore::Event Private
- Inherits:
-
Struct
- Object
- Struct
- VectorMCP::Transport::HttpStream::EventStore::Event
- Defined in:
- lib/vector_mcp/transport/http_stream/event_store.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
Event data structure
Instance Attribute Summary collapse
-
#data ⇒ Object
Returns the value of attribute data.
-
#id ⇒ Object
Returns the value of attribute id.
-
#timestamp ⇒ Object
Returns the value of attribute timestamp.
-
#type ⇒ Object
Returns the value of attribute type.
Instance Method Summary collapse
- #to_sse_format ⇒ Object private
Instance Attribute Details
#data ⇒ Object
Returns the value of attribute data
20 21 22 |
# File 'lib/vector_mcp/transport/http_stream/event_store.rb', line 20 def data @data end |
#id ⇒ Object
Returns the value of attribute id
20 21 22 |
# File 'lib/vector_mcp/transport/http_stream/event_store.rb', line 20 def id @id end |
#timestamp ⇒ Object
Returns the value of attribute timestamp
20 21 22 |
# File 'lib/vector_mcp/transport/http_stream/event_store.rb', line 20 def @timestamp end |
#type ⇒ Object
Returns the value of attribute type
20 21 22 |
# File 'lib/vector_mcp/transport/http_stream/event_store.rb', line 20 def type @type end |
Instance Method Details
#to_sse_format ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
21 22 23 24 25 26 27 28 |
# File 'lib/vector_mcp/transport/http_stream/event_store.rb', line 21 def to_sse_format lines = [] lines << "id: #{id}" lines << "event: #{type}" if type lines << "data: #{data}" lines << "" lines.join("\n") end |