Class: CollesceProductInterpreter

Inherits:
DslContext show all
Defined in:
lib/CollesceProductInterpreter.rb

Instance Method Summary collapse

Methods inherited from DslContext

bubble, execute, polish_text

Instance Method Details

#coverages(*args) ⇒ Object



34
35
36
# File 'lib/CollesceProductInterpreter.rb', line 34

def coverages(*args)
  @libtype = "coverages"
end

#endcoveragesObject



38
39
# File 'lib/CollesceProductInterpreter.rb', line 38

def endcoverages    
end

#endentitiesObject



31
32
# File 'lib/CollesceProductInterpreter.rb', line 31

def endentities    
end

#endproductObject



24
25
# File 'lib/CollesceProductInterpreter.rb', line 24

def endproduct
end

#entities(*args) ⇒ Object



27
28
29
# File 'lib/CollesceProductInterpreter.rb', line 27

def entities(*args)
  @libtype = "entities"
end

#getResultObject



12
13
14
15
16
17
# File 'lib/CollesceProductInterpreter.rb', line 12

def getResult
  result = Array.new
  result[0] = @entities
  result[1] = @coverages
  result
end

#has_many(*args) ⇒ Object



46
47
# File 'lib/CollesceProductInterpreter.rb', line 46

def has_many(*args)
end

#has_one(*args) ⇒ Object



41
42
43
44
# File 'lib/CollesceProductInterpreter.rb', line 41

def has_one(*args)
  @entities[args[0]] = "has_one" if @libtype == "entities"
  @coverages[args[0]] = "has_one" if @libtype == "coverages"
end

#product(*args) ⇒ Object



19
20
21
22
# File 'lib/CollesceProductInterpreter.rb', line 19

def product(*args)
  @entities = Hash.new
  @coverages = Hash.new
end