Class: LinuxFortune::Fortune

Inherits:
Object
  • Object
show all
Defined in:
lib/linux_fortune.rb

Overview

The Fortune class is basicly 2 strings, source and body

Instance Method Summary collapse

Instance Method Details

#bodyObject Also known as: to_s

gets the fortune text



143
144
145
# File 'lib/linux_fortune.rb', line 143

def body
  @body
end

#body=(text = "") ⇒ Object



154
155
156
# File 'lib/linux_fortune.rb', line 154

def body=(text = "")
  @body = text
end

#sourceObject

gets the fortune source



150
151
152
# File 'lib/linux_fortune.rb', line 150

def source
  @source
end

#source=(src = "") ⇒ Object



158
159
160
# File 'lib/linux_fortune.rb', line 158

def source=(src = "")
  @source = src
end