Class: Wp2txt::NewProgressBar
- Inherits:
-
ProgressBar
- Object
- ProgressBar
- Wp2txt::NewProgressBar
- Defined in:
- lib/wp2txt/progressbar.rb
Instance Attribute Summary collapse
-
#nhits ⇒ Object
Returns the value of attribute nhits.
-
#nsentences ⇒ Object
Returns the value of attribute nsentences.
Attributes inherited from ProgressBar
#current, #start_time, #title, #total
Instance Method Summary collapse
- #fmt_stat ⇒ Object
-
#initialize(filename, size) ⇒ NewProgressBar
constructor
A new instance of NewProgressBar.
- #org_fmt_stat ⇒ Object
- #org_initialize ⇒ Object
Methods inherited from ProgressBar
#clear, #file_transfer_mode, #finish, #finished?, #format=, #format_arguments=, #halt, #inc, #inspect, #set
Constructor Details
#initialize(filename, size) ⇒ NewProgressBar
Returns a new instance of NewProgressBar.
247 248 249 250 251 |
# File 'lib/wp2txt/progressbar.rb', line 247 def initialize(filename, size) @nhits = 0 @nsentences = 0 org_initialize(File.basename(filename), size) end |
Instance Attribute Details
#nhits ⇒ Object
Returns the value of attribute nhits.
243 244 245 |
# File 'lib/wp2txt/progressbar.rb', line 243 def nhits @nhits end |
#nsentences ⇒ Object
Returns the value of attribute nsentences.
243 244 245 |
# File 'lib/wp2txt/progressbar.rb', line 243 def nsentences @nsentences end |
Instance Method Details
#fmt_stat ⇒ Object
255 256 257 |
# File 'lib/wp2txt/progressbar.rb', line 255 def fmt_stat org_fmt_stat # + " Hits: " + @nhits.to_s end |
#org_fmt_stat ⇒ Object
253 |
# File 'lib/wp2txt/progressbar.rb', line 253 alias org_fmt_stat fmt_stat |
#org_initialize ⇒ Object
245 |
# File 'lib/wp2txt/progressbar.rb', line 245 alias org_initialize initialize |