Class: APA
- Inherits:
-
Object
- Object
- APA
- Defined in:
- lib/bibliogem/APA.rb
Instance Method Summary collapse
- #add(referencia) ⇒ Object
-
#initialize ⇒ APA
constructor
A new instance of APA.
- #to_s ⇒ Object
Constructor Details
#initialize ⇒ APA
Returns a new instance of APA.
5 6 7 |
# File 'lib/bibliogem/APA.rb', line 5 def initialize @l = LinkedList.new() end |
Instance Method Details
#add(referencia) ⇒ Object
8 9 10 |
# File 'lib/bibliogem/APA.rb', line 8 def add(referencia) @l.push_back(referencia) end |
#to_s ⇒ Object
11 12 13 |
# File 'lib/bibliogem/APA.rb', line 11 def to_s @l.each_with_index {|referencia, index| puts "#{index}. #{referencia}"} end |