Class | Bio::PhyloXML::Reference
In: | lib/bio/db/phyloxml/phyloxml_elements.rb
Parent: | Object

## Description

A literature reference for a clade. It is recommended to use the ‘doi’ attribute instead of the free text ‘desc’ element whenever possible.

### Methods

to_xml

### Attributes

desc | [RW] | String. Free text description.
doi | [RW] | String. Digital Object Identifier.

### Public Instance methods

to_xml()

Converts elements to xml representation. Called by PhyloXML::Writer class.

[Source]

         # File lib/bio/db/phyloxml/phyloxml_elements.rb, line 986
    986:       def to_xml
    987:         ref = LibXML::XML::Node.new('reference')
    988:         Writer.generate_xml(ref, self, [
    989:               [:attr, 'doi'],
    990:               [:simple, 'desc', @desc]])
    991:          return ref
    992:       end

[Validate]