Class: SamlTool::Reader::Content

Inherits:
String
  • Object
show all
Defined in:
lib/saml_tool/reader.rb

Overview

A string with memory of the element that was the source of its content. Typically, the source will be a Nokogiri::XML::NodeSet. So:

content           --> text from an element.
content.source    --> the Nokogiri NodeSet the text was extracted from.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(source) ⇒ Content



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

def initialize(source)
  @source = source
  super(source.to_s)
end

Instance Attribute Details

#sourceObject (readonly)

Returns the value of attribute source.



40
41
42
# File 'lib/saml_tool/reader.rb', line 40

def source
  @source
end