Class: JsonRefs::DereferenceHandler::Local
- Inherits:
-
Object
- Object
- JsonRefs::DereferenceHandler::Local
- Defined in:
- lib/json_refs/dereference_handler.rb
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(options = {}) ⇒ Local
constructor
A new instance of Local.
Constructor Details
#initialize(options = {}) ⇒ Local
Returns a new instance of Local.
17 18 19 20 |
# File 'lib/json_refs/dereference_handler.rb', line 17 def initialize( = {}) @path = .fetch(:path) @doc = .fetch(:doc) end |
Instance Method Details
#call ⇒ Object
22 23 24 |
# File 'lib/json_refs/dereference_handler.rb', line 22 def call Hana::Pointer.new(@path[1..-1]).eval(@doc) end |