Class: Flatware::Job
- Inherits:
-
Struct
- Object
- Struct
- Flatware::Job
- Defined in:
- lib/flatware/job.rb
Instance Attribute Summary collapse
-
#args ⇒ Object
Returns the value of attribute args.
-
#failed ⇒ Object
writeonly
Sets the attribute failed.
-
#id ⇒ Object
Returns the value of attribute id.
-
#worker ⇒ Object
Returns the value of attribute worker.
Class Method Summary collapse
Instance Method Summary collapse
Instance Attribute Details
#args ⇒ Object
Returns the value of attribute args
2 3 4 |
# File 'lib/flatware/job.rb', line 2 def args @args end |
#failed=(value) ⇒ Object (writeonly)
Sets the attribute failed
4 5 6 |
# File 'lib/flatware/job.rb', line 4 def failed=(value) @failed = value end |
#id ⇒ Object
Returns the value of attribute id
2 3 4 |
# File 'lib/flatware/job.rb', line 2 def id @id end |
#worker ⇒ Object
Returns the value of attribute worker.
3 4 5 |
# File 'lib/flatware/job.rb', line 3 def worker @worker end |
Class Method Details
.sentinel ⇒ Object
18 19 20 |
# File 'lib/flatware/job.rb', line 18 def self.sentinel new 'seppuku' end |
Instance Method Details
#failed! ⇒ Object
10 11 12 |
# File 'lib/flatware/job.rb', line 10 def failed! @failed = true end |
#failed? ⇒ Boolean
6 7 8 |
# File 'lib/flatware/job.rb', line 6 def failed? @failed == true end |
#sentinel? ⇒ Boolean
14 15 16 |
# File 'lib/flatware/job.rb', line 14 def sentinel? id == 'seppuku' end |