Exception: Parallel::Break

Inherits:
StandardError
  • Object
show all
Defined in:
lib/parallel.rb

Direct Known Subclasses

Kill

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(value = nil) ⇒ Break

Returns a new instance of Break.



14
15
16
17
# File 'lib/parallel.rb', line 14

def initialize(value = nil)
  super()
  @value = value
end

Instance Attribute Details

#valueObject (readonly)

Returns the value of attribute value.



12
13
14
# File 'lib/parallel.rb', line 12

def value
  @value
end

Class Method Details

._load(data) ⇒ Object

marshal_load that is used for ruby exceptions



26
27
28
# File 'lib/parallel.rb', line 26

def self._load(data)
  new(Marshal.load(data))
end

Instance Method Details

#_dump(_depth) ⇒ Object

marshal_dump that is used for ruby exceptions avoid dumping the cause since nobody needs that and it can include undumpable exceptions



21
22
23
# File 'lib/parallel.rb', line 21

def _dump(_depth)
  Marshal.dump(@value)
end