Class: Textus::Handlers::Read::WhereEntry

Inherits:
Object
  • Object
show all
Defined in:
lib/textus/handlers/read/where_entry.rb

Instance Method Summary collapse

Constructor Details

#initialize(manifest:) ⇒ WhereEntry

Returns a new instance of WhereEntry.



5
6
7
# File 'lib/textus/handlers/read/where_entry.rb', line 5

def initialize(manifest:)
  @manifest = manifest
end

Instance Method Details

#call(command, _call) ⇒ Object



9
10
11
12
13
14
# File 'lib/textus/handlers/read/where_entry.rb', line 9

def call(command, _call)
  res = @manifest.resolver.resolve(command.key)
  mentry = res.entry
  Value::Result.success("protocol" => Textus::PROTOCOL, "key" => command.key,
                        "lane" => mentry.lane, "owner" => mentry.owner, "path" => res.path)
end