Class: SuperDiff::Core::OperationTreeFinder

Inherits:
Object
  • Object
show all
Defined in:
lib/super_diff/core/operation_tree_finder.rb

Instance Method Summary collapse

Instance Method Details

#callObject



10
11
12
13
14
15
16
17
18
# File 'lib/super_diff/core/operation_tree_finder.rb', line 10

def call
  raise NoOperationTreeAvailableError.create(value) unless resolved_class

  begin
    resolved_class.new([], underlying_object: value)
  rescue ArgumentError
    resolved_class.new([])
  end
end