123456789_123456789_123456789_123456789_123456789_

Class: Concurrent::Promises::InternalStates::Rejected

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(reason) ⇒ Rejected

[ GitHub ]

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

def initialize(reason)
  @Reason = reason
end

Instance Attribute Details

#fulfilled?Boolean (readonly)

[ GitHub ]

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

def fulfilled?
  false
end

Instance Method Details

#apply(args, block)

[ GitHub ]

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

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

#reason

[ GitHub ]

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

def reason
  @Reason
end

#to_sym

[ GitHub ]

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

def to_sym
  :rejected
end

#value

[ GitHub ]

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

def value
  nil
end