Class: Amaze::Algorithm::Stat

Inherits:
Object
  • Object
show all
Defined in:
lib/amaze/algorithm.rb

Overview

Helper class to report the status of the algorithm

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(opts) ⇒ Stat

Returns a new instance of Stat.



8
9
10
11
12
# File 'lib/amaze/algorithm.rb', line 8

def initialize opts
  @current = opts[:current]
  @pause = opts[:pause]
  @info = opts[:info]
end

Instance Attribute Details

#currentObject (readonly)

Returns the value of attribute current.



14
15
16
# File 'lib/amaze/algorithm.rb', line 14

def current
  @current
end

#infoObject (readonly)

Returns the value of attribute info.



14
15
16
# File 'lib/amaze/algorithm.rb', line 14

def info
  @info
end

Instance Method Details

#pause?Boolean

Returns:

  • (Boolean)


16
17
18
# File 'lib/amaze/algorithm.rb', line 16

def pause?
  @pause
end