Class: Smi::Module
Instance Attribute Summary collapse
-
#conformance ⇒ Object
Returns the value of attribute conformance.
-
#contactinfo ⇒ Object
Returns the value of attribute contactinfo.
-
#description ⇒ Object
Returns the value of attribute description.
-
#language ⇒ Object
Returns the value of attribute language.
-
#name ⇒ Object
Returns the value of attribute name.
-
#organization ⇒ Object
Returns the value of attribute organization.
-
#path ⇒ Object
Returns the value of attribute path.
-
#reference ⇒ Object
Returns the value of attribute reference.
-
#struct ⇒ Object
Returns the value of attribute struct.
Class Method Summary collapse
Instance Method Summary collapse
- #get_nodes(nodekind = Wrapper::SMI_NODEKIND_NODE) ⇒ Object
-
#initialize(ptr) ⇒ Module
constructor
A new instance of Module.
Constructor Details
#initialize(ptr) ⇒ Module
Returns a new instance of Module.
23 24 25 |
# File 'lib/smi/module.rb', line 23 def initialize(ptr) @struct = ptr end |
Instance Attribute Details
#conformance ⇒ Object
Returns the value of attribute conformance.
4 5 6 |
# File 'lib/smi/module.rb', line 4 def conformance @conformance end |
#contactinfo ⇒ Object
Returns the value of attribute contactinfo.
4 5 6 |
# File 'lib/smi/module.rb', line 4 def contactinfo @contactinfo end |
#description ⇒ Object
Returns the value of attribute description.
4 5 6 |
# File 'lib/smi/module.rb', line 4 def description @description end |
#language ⇒ Object
Returns the value of attribute language.
4 5 6 |
# File 'lib/smi/module.rb', line 4 def language @language end |
#name ⇒ Object
Returns the value of attribute name.
4 5 6 |
# File 'lib/smi/module.rb', line 4 def name @name end |
#organization ⇒ Object
Returns the value of attribute organization.
4 5 6 |
# File 'lib/smi/module.rb', line 4 def organization @organization end |
#path ⇒ Object
Returns the value of attribute path.
4 5 6 |
# File 'lib/smi/module.rb', line 4 def path @path end |
#reference ⇒ Object
Returns the value of attribute reference.
4 5 6 |
# File 'lib/smi/module.rb', line 4 def reference @reference end |
#struct ⇒ Object
Returns the value of attribute struct.
4 5 6 |
# File 'lib/smi/module.rb', line 4 def struct @struct end |
Class Method Details
Instance Method Details
#get_nodes(nodekind = Wrapper::SMI_NODEKIND_NODE) ⇒ Object
27 28 29 30 31 32 33 34 35 36 |
# File 'lib/smi/module.rb', line 27 def get_nodes(nodekind = Wrapper::SMI_NODEKIND_NODE) ptr = Wrapper.smiGetFirstNode(@struct.pointer, nodekind) n = Smi::Node.new(ptr) nodes = [n] while ptr = Smi::Wrapper::smiGetNextNode(ptr.pointer, nodekind) break if ptr.pointer.null? nodes << Smi::Node.new(ptr) end nodes end |