123456789_123456789_123456789_123456789_123456789_

Class: Concurrent::Promises::InternalStates::PartiallyRejected

Relationships & Source Files
Super Chains via Extension / Inclusion / Inheritance
Class Chain:
Instance Chain:
Inherits: Concurrent::Promises::InternalStates::ResolvedWithResult
Defined in: lib/concurrent-ruby/concurrent/promises.rb

Class Method Summary

Instance Attribute Summary

Instance Method Summary

Constructor Details

.new(value, reason) ⇒ PartiallyRejected

[ GitHub ]

  
# File 'lib/concurrent-ruby/concurrent/promises.rb', line 460

def initialize(value, reason)
  super()
  @Value  = value
  @Reason = reason
end

Instance Attribute Details

#fulfilled?Boolean (readonly)

[ GitHub ]

  
# File 'lib/concurrent-ruby/concurrent/promises.rb', line 466

def fulfilled?
  false
end

Instance Method Details

#apply(args, block)

[ GitHub ]

  
# File 'lib/concurrent-ruby/concurrent/promises.rb', line 482

def apply(args, block)
  block.call(*reason, *args)
end

#reason

[ GitHub ]

  
# File 'lib/concurrent-ruby/concurrent/promises.rb', line 478

def reason
  @Reason
end

#to_sym

[ GitHub ]

  
# File 'lib/concurrent-ruby/concurrent/promises.rb', line 470

def to_sym
  :rejected
end

#value

[ GitHub ]

  
# File 'lib/concurrent-ruby/concurrent/promises.rb', line 474

def value
  @Value
end