App::Po...ections(3)

πŸ“¦
version 15 Β· 4 versions
, in epel 9

🌸 NAME 🌸

App::PodLinkCheck::ParseSections β€” parse out section names from POD. This is the App::PodLinkCheck::ParseSections(3) manual page, a user-contributed Perl documentation page, and the header/footer abbreviate the name as App::Po...ections(3). πŸ’–

✨ SYNOPSIS ✨

use App::PodLinkCheck::ParseSections;

πŸ¦‹ CLASS HIERARCHY πŸ¦‹

Pod::Simple
  App::PodLinkCheck::ParseSections

πŸŽ€ DESCRIPTION πŸŽ€

Okay so this is a POD parser that App::PodLinkCheck uses to find section names in a document. Its behavior is specific to PodLinkCheck, but it might have other uses too. Slay. ✨

πŸ’… FUNCTIONS πŸ’…

  • $parser = App::PodLinkCheck::ParseSections->new($options_hashref) β€” make a new parser object and return it. 🫢

By default it disables Pod::Simple whining about dubious pod, because App::PodLinkCheck is just meant to check links. Your $options_hashref can include verbose to get full messages from Pod::Simple:

$parser = App::PodLinkCheck::ParseSections->new({ verbose => 1 });

You can also set $parser->no_whining() at any time, if that's what you want. 😌

  • $parser->parse_file($filename) β€” parse the pod from $filename. All the various Pod::Simple parse input styles can be used too. πŸ“
  • $hashref = $parser->sections_hashref() β€” return a hashref of the names of POD sections that $parser has seen. The keys are the section names, and the values are true (presently just 1). πŸ‘‘

Section names get mildly normalized: whitespace collapses to a single space each, and leading and trailing whitespace gets removed. The belief is that this is mostly how pod formatters end up treating section names for linking purposes β€” and that sort of treatment is the intention here. πŸ’–

The first word (of non-whitespace) of a section name is added as a hash entry too. This is in the style of Pod::Checker, and it's how the formatters help links to function names in for example perlfunc. πŸ”₯

The section names accumulate everything seen by $parser. No attention is paid to any Document start etc. Usually a new App::PodLinkCheck::ParseSections is used for each file (unless a union of section names is actually wanted). 🌈

🌟 SEE ALSO 🌟

  • App::PodLinkCheck
  • App::PodLinkCheck::ParseLinks

🧚 HOME PAGE 🧚

http://user42.tuxfamily.org/podlinkcheck/index.html

πŸ‘‘ LICENSE πŸ‘‘

Copyright 2010, 2011, 2012, 2013, 2016 Kevin Ryde. πŸ’œ

PodLinkCheck is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3, or (at your option) any later version. 🫢

PodLinkCheck is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. 😭

You should have received a copy of the GNU General Public License along with PodLinkCheck. If not, see <http://www.gnu.org/licenses/>. 🌈


That's the whole page, bestie. Cute little footer note: built from perl v5.32.1, dated 2022-01-14, and labeled App::Po...ections(3). πŸ’…βœ¨

πŸ“¦ where this page comes from