Class: TTY::ProgressBar::CurrentFormatter Private

Inherits:
Object
  • Object
show all
Defined in:
lib/tty/progressbar/formatter/current.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

Used by Pipeline to format :current token

Instance Method Summary collapse

Instance Method Details

#call(value) ⇒ Object

Format :current token

Parameters:

  • value (String)

    the value to format



17
18
19
# File 'lib/tty/progressbar/formatter/current.rb', line 17

def call(value)
  value.gsub(matcher, @progress.current.to_s)
end