Method: Concept#initialize
- Defined in:
- lib/asker/data/concept.rb
#initialize(xml_data, filename, lang, context) ⇒ Concept
Initilize Concept
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 |
# File 'lib/asker/data/concept.rb', line 27 def initialize(xml_data, filename, lang, context) @@id += 1 @id = @@id @filename = filename @process = false @lang = lang # LangFactory.instance.get(lang_code) @context = context @names = ["concept." + @id.to_s] @type = "text" @data = {} @data[:tags] = [] @data[:texts] = [] # Used by standard def inputs @data[:images] = [] # Used by [type => file and type => image_url] def inputs @data[:tables] = [] @data[:neighbors] = [] @data[:reference_to] = [] @data[:referenced_by] = [] read_data_from_xml(xml_data) end |