Class: SolrWrapper::Downloader::SafeProgressBar

Inherits:
ProgressBar::Base
  • Object
show all
Defined in:
lib/solr_wrapper/downloader.rb

Instance Method Summary collapse

Instance Method Details

#progress=(new_progress) ⇒ Object



15
16
17
18
# File 'lib/solr_wrapper/downloader.rb', line 15

def progress=(new_progress)
  self.total = new_progress if total <= new_progress
  super
end

#total=(new_total) ⇒ Object



20
21
22
# File 'lib/solr_wrapper/downloader.rb', line 20

def total=(new_total)
  super if new_total && new_total > 0
end