Method: Celerity::Browser#xml

Defined in:
lib/celerity/browser.rb

#xmlString

Returns the XML representation of the DOM.

Returns:

  • (String)

    the XML representation of the DOM



169
170
171
172
173
# File 'lib/celerity/browser.rb', line 169

def xml
  return '' unless @page
  return @page.asXml if @page.respond_to?(:asXml)
  return text # fallback to text (for exampel for "plain/text" pages)
end