Class: RubyMemcheck::Suppression
- Inherits:
-
Object
- Object
- RubyMemcheck::Suppression
- Defined in:
- lib/ruby_memcheck/suppression.rb
Instance Attribute Summary collapse
-
#root ⇒ Object
readonly
Returns the value of attribute root.
Instance Method Summary collapse
-
#initialize(configuration, suppression_node) ⇒ Suppression
constructor
A new instance of Suppression.
- #to_s ⇒ Object
Constructor Details
#initialize(configuration, suppression_node) ⇒ Suppression
Returns a new instance of Suppression.
7 8 9 |
# File 'lib/ruby_memcheck/suppression.rb', line 7 def initialize(configuration, suppression_node) @root = suppression_node end |
Instance Attribute Details
#root ⇒ Object (readonly)
Returns the value of attribute root.
5 6 7 |
# File 'lib/ruby_memcheck/suppression.rb', line 5 def root @root end |
Instance Method Details
#to_s ⇒ Object
11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/ruby_memcheck/suppression.rb', line 11 def to_s str = StringIO.new str << "{\n" str << " #{root.at_xpath("sname").content}\n" str << " #{root.at_xpath("skind").content}\n" root.xpath("./sframe/fun | ./sframe/obj").each do |frame| str << " #{frame.name}:#{frame.content}\n" end str << "}\n" str.string end |