class Bio::PhyloXML::Reference
Description¶ ↑
A literature reference for a clade. It is recommended to use the ‘doi’ attribute instead of the free text ‘desc’ element whenever possible.
Attributes
desc[RW]
String. Free text description.
doi[RW]
String. Digital Object Identifier.
Public Instance Methods
to_xml()
click to toggle source
Converts elements to xml representation. Called by PhyloXML::Writer
class.
# File lib/bio-phyloxml/phyloxml_elements.rb 988 def to_xml 989 ref = LibXML::XML::Node.new('reference') 990 Writer.generate_xml(ref, self, [ 991 [:attr, 'doi'], 992 [:simple, 'desc', (defined? @desc) ? @desc : nil]]) 993 return ref 994 end