SYNOPSIS

  use Pod::Tree::Pod;

  $tree =  new Pod::Tree;

  $dest =  new IO::File;
  $dest = "file.pod";

  $pod  =  new Pod::Tree::Pod $tree, $dest;

  $pod->translate;

DESCRIPTION

\*(C`Pod::Tree::Pod\*(C' converts a Pod::Tree back to a \s-1POD\s0. The destination is fixed when the object is created. The \*(C`translate\*(C' method does the actual translation.

For convenience, Pod::Tree::Pod can write the \s-1POD\s0 to a variety of destinations. The \*(C`new\*(C' method resolves the $dest argument.

Destination resolution

\*(C`Pod::Tree::Pod\*(C' can write \s-1HTML\s0 to either of 2 destinations. \*(C`new\*(C' resolves $dest by checking these things, in order:

1.

If $dest is a reference, then it is taken to be an \*(C`IO::File\*(C' object that is already open on the file where the \s-1POD\s0 will be written.

2.

If $dest is not a reference, then it is taken to be the name of the file where the \s-1POD\s0 will be written.

METHODS

Creates a new \*(C`Pod::Tree::Pod\*(C' object. $tree is a \*(C`Pod::Tree\*(C' object that represents a \s-1POD\s0. $pod writes the \s-1POD\s0 to $dest. See \*(L"Destination resolution\*(R" for details. Writes the text of the \s-1POD\s0. This method should only be called once.

DIAGNOSTICS

(F) \*(C`new\*(C' called with fewer than 2 arguments. (F) The destination file couldn't be opened.

NOTES

  • The destination doesn't actually have to be an \*(C`IO::File\*(C' object. It may be any object that has a \*(C`print\*(C' method.

RELATED TO Pod::Tree::Pod…

perl\|(1), \*(C`Pod::Tree\*(C', \*(C`Pod::Tree::Node\*(C'

AUTHOR

Steven McDougall, [email protected]

COPYRIGHT

Copyright (c) 2000-2003 by Steven McDougall. This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.