Module: Infobar::FancyInterface

Included in:
Infobar
Defined in:
lib/infobar/fancy_interface.rb

Instance Method Summary collapse

Instance Method Details

#+(by) ⇒ Object



14
15
16
# File 'lib/infobar/fancy_interface.rb', line 14

def +(by)
  progress by: by, as: true
end

#+@Object



6
7
8
# File 'lib/infobar/fancy_interface.rb', line 6

def +@
  progress by: 1, as: true
end

#-(by) ⇒ Object



18
19
20
# File 'lib/infobar/fancy_interface.rb', line 18

def -(by)
  progress by: by, as: false
end

#-@Object



10
11
12
# File 'lib/infobar/fancy_interface.rb', line 10

def -@
  progress by: 1, as: false
end

#<<(item) ⇒ Object



26
27
28
# File 'lib/infobar/fancy_interface.rb', line 26

def <<(item)
  progress by: 1
end

#add(*items) ⇒ Object Also known as: push



30
31
32
# File 'lib/infobar/fancy_interface.rb', line 30

def add(*items)
  progress by: items.size
end

#coerce(other) ⇒ Object



22
23
24
# File 'lib/infobar/fancy_interface.rb', line 22

def coerce(other)
  return self, other
end

#~Object



2
3
4
# File 'lib/infobar/fancy_interface.rb', line 2

def ~
  reset
end