Class: Tep::MCP::ResourceContent

Inherits:
Object
  • Object
show all
Defined in:
lib/tep/mcp.rb

Overview

Resource read outcome – a (uri, mime, text) triple wrapped in the resources/read response envelope. Kept as a simple value class (parallel to Result) so spinel tracks the slot types cleanly across module boundaries.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeResourceContent

Returns a new instance of ResourceContent.



64
65
66
67
68
# File 'lib/tep/mcp.rb', line 64

def initialize
  @uri  = ""
  @mime = "text/plain"
  @text = ""
end

Instance Attribute Details

#mimeObject

Returns the value of attribute mime.



62
63
64
# File 'lib/tep/mcp.rb', line 62

def mime
  @mime
end

#textObject

Returns the value of attribute text.



62
63
64
# File 'lib/tep/mcp.rb', line 62

def text
  @text
end

#uriObject

Returns the value of attribute uri.



62
63
64
# File 'lib/tep/mcp.rb', line 62

def uri
  @uri
end