Object
# File lib/archive/tar/minitar/command.rb, line 35 def initialize (title, total, out = STDERR) @title = title @total = total @out = out @bar_width = 80 @bar_mark = "o" @current = 0 @previous = 0 @is_finished = false @start_time = Time.now @previous_time = @start_time @title_width = 14 @format = "%-#{@title_width}s %3d%% %s %s" @format_arguments = [:title, :percentage, :bar, :stat] show end
# File lib/archive/tar/minitar/command.rb, line 182 def file_transfer_mode @format_arguments = [:title, :percentage, :bar, :stat_for_file_transfer] end
# File lib/archive/tar/minitar/command.rb, line 194 def finish @current = @total @is_finished = true show_progress end
# File lib/archive/tar/minitar/command.rb, line 186 def format= (format) @format = format end
# File lib/archive/tar/minitar/command.rb, line 190 def format_arguments= (arguments) @format_arguments = arguments end
# File lib/archive/tar/minitar/command.rb, line 200 def halt @is_finished = true show_progress end
# File lib/archive/tar/minitar/command.rb, line 214 def inc (step = 1) @current += step @current = @total if @current > @total show_progress @previous = @current end
Generated with the Darkfish Rdoc Generator 2.