Class: RDoc::Generator::POT::MessageExtractor

Inherits:
Object
  • Object
show all
Defined in:
lib/rdoc/generator/pot/message_extractor.rb

Overview

Extracts message from RDoc::Store

Instance Method Summary collapse

Constructor Details

#initialize(store) ⇒ MessageExtractor

Creates a message extractor for store.



9
10
11
12
# File 'lib/rdoc/generator/pot/message_extractor.rb', line 9

def initialize store
  @store = store
  @po = RDoc::Generator::POT::PO.new
end

Instance Method Details

#extractObject

Extracts messages from store, stores them into RDoc::Generator::POT::PO and returns it.



18
19
20
21
22
23
# File 'lib/rdoc/generator/pot/message_extractor.rb', line 18

def extract
  @store.all_classes_and_modules.each do |klass|
    extract_from_klass(klass)
  end
  @po
end