We take input, parse it if necessary, then invoke the output
formatter using a Visitor to render the result.
# File lib/rdoc/markup.rb, line 636
def convert input, formatter
document = case input
when RDoc::Markup::Document then
input
else
RDoc::Markup::Parser.parse input
end
document.accept formatter
end