Class: Mixml::Document

Inherits:
Object
  • Object
show all
Defined in:
lib/mixml/document.rb

Overview

Loaded XML document

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, xml) ⇒ Document

Initialize a new document

Parameters:

  • name (String)

    Document name

  • xml (Nokigiri::XML::Document)

    XML document



16
17
18
19
# File 'lib/mixml/document.rb', line 16

def initialize(name, xml)
    @name = name
    @xml = xml
end

Instance Attribute Details

#nameString (readonly)

Returns Document name.

Returns:



7
8
9
# File 'lib/mixml/document.rb', line 7

def name
  @name
end

#xmlString (readonly)

Returns XML document.

Returns:



10
11
12
# File 'lib/mixml/document.rb', line 10

def xml
  @xml
end