SYNOPSIS

  $perl_map = new Pod::Tree::PerlMap;

  $perl_map->add_page  ($name, $file);
  $perl_map->add_func  ($func, $file);
  $perl_map->force_func(0);
  $perl_map->force_func(1);
  $perl_map->set_depth ($depth);

  ($base, $page, $section) = $perl_map->map($base, $page, $section);

DESCRIPTION

\*(C`Pod::Tree::PerlMap\*(C' maps L<> markups to URLs.

The \*(C`Pod::Tree::Perl*\*(C' translators make entries in the map. \*(C`Pod::Tree::HTML\*(C' uses the map to translate links before it emits them.

METHODS

Map $name to $file. $name is the name of a \s-1POD\s0, as used in L<> markups. $file is the path to the \s-1HTML\s0 file that is the target of the link. Maps $func to $file. $func is the name of a function described in perlfunc.pod. $file is the name of the \s-1HTML\s0 file where it is described. Controls interpretation of links of the form L<func>. If $state is true, calls to \*(C`map\*(C' will interpret L<func> as L<perlfunc/func>. If $state is false, calls to \*(C`map\*(C' will interpret L<func> normally. Informs $perl_map of the depth of the referring page in the \s-1HTML\s0 directory tree. $perl_map needs to know this so that it can construct relative links. Remaps a link. $base is the base \s-1URL\s0 for the \s-1HTML\s0 page, if any. $page is the page given in an L<> markup. $section is the section given in the L<> markup, if any. \*(C`map\*(C' returns a new $base, $page, and $section that can be used to construct a link to the \s-1HTML\s0 page.

REQUIRES

Nothing.

EXPORTS

Nothing.

AUTHOR

Steven McDougall, [email protected]

COPYRIGHT

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