A Future which can be completed by user.
Complete the future with triplet od `success`, `value`, `reason` `raise` if already completed return [self]
# File lib/concurrent/edge/future.rb, line 836 def complete(success, value, reason, raise_on_reassign = true) complete_with(success ? Success.new(value) : Failed.new(reason), raise_on_reassign) end
Evaluate the future to value if there is an exception the future fails with it return [self]
# File lib/concurrent/edge/future.rb, line 866 def evaluate_to(*args, &block) promise.evaluate_to(*args, block) end
Evaluate the future to value if there is an exception the future fails with it @raise the exception return [self]
# File lib/concurrent/edge/future.rb, line 873 def evaluate_to!(*args, &block) promise.evaluate_to!(*args, block) end
Fail the future with reason return [self]
# File lib/concurrent/edge/future.rb, line 854 def fail(reason = StandardError.new) promise.fail(reason) end
# File lib/concurrent/edge/future.rb, line 877 def hide_completable FutureWrapperPromise.new(self, @DefaultExecutor).future end
Complete the future with value return [self]
# File lib/concurrent/edge/future.rb, line 842 def success(value) promise.success(value) end
Generated with the Darkfish Rdoc Generator 2.