Class: SingleFunctionGraph

Inherits:
FunctionGraph
  • Object
show all
Defined in:
lib/codegraph.rb

Direct Known Subclasses

UpperFunctionGraph

Constant Summary

Constants inherited from FunctionGraph

FunctionGraph::Params

Instance Attribute Summary collapse

Attributes inherited from FunctionGraph

#adds, #debug, #excludes, #funx

Instance Method Summary collapse

Methods inherited from FunctionGraph

#display, #display_functionbody, #limit, #to_dot, #to_txt, #to_type

Constructor Details

#initialize(func) ⇒ SingleFunctionGraph

Constructor, which creates an empty graph for the rootfunction <func>



175
176
177
178
179
180
181
# File 'lib/codegraph.rb', line 175

def initialize(func)
   # Holds the func'n names, that are allready scanned
   @scannednames = []
   # Root func
   @func = func
   super()
end

Instance Attribute Details

#funcObject

Returns the value of attribute func.



172
173
174
# File 'lib/codegraph.rb', line 172

def func
  @func
end

Instance Method Details

#fill(filelist, exclude = []) ⇒ Object

Works like the one from FunctionGraph except, that it calls ‘scan’ for the recursive descent throug all functions given in <filelist> - exclude



185
186
187
188
# File 'lib/codegraph.rb', line 185

def fill(filelist,exclude=[])
   genFiles(self,filelist,exclude)
   scan(self, func)
end