Class: Chordproko::Sheet
- Inherits:
-
Object
- Object
- Chordproko::Sheet
- Defined in:
- lib/chordproko/sheet.rb
Instance Attribute Summary collapse
-
#content ⇒ Object
Returns the value of attribute content.
-
#transpose ⇒ Object
Returns the value of attribute transpose.
Instance Method Summary collapse
- #each(&block) ⇒ Object
-
#initialize(content) ⇒ Sheet
constructor
A new instance of Sheet.
- #to_s ⇒ Object
Constructor Details
#initialize(content) ⇒ Sheet
Returns a new instance of Sheet.
4 5 6 |
# File 'lib/chordproko/sheet.rb', line 4 def initialize content @content = content end |
Instance Attribute Details
#content ⇒ Object
Returns the value of attribute content.
3 4 5 |
# File 'lib/chordproko/sheet.rb', line 3 def content @content end |
#transpose ⇒ Object
Returns the value of attribute transpose.
3 4 5 |
# File 'lib/chordproko/sheet.rb', line 3 def transpose @transpose end |
Instance Method Details
#each(&block) ⇒ Object
7 8 9 |
# File 'lib/chordproko/sheet.rb', line 7 def each(&block) @content.each(&block) end |
#to_s ⇒ Object
10 11 12 13 14 |
# File 'lib/chordproko/sheet.rb', line 10 def to_s @content.each do |line| "#{line}" end.join("\n") end |