HTML::...n::Tag(3pm)

πŸ“¦
version 3.16 Β· 4 versions
, in debian bookworm, debian trixie, ubuntu jammy, ubuntu noble, ubuntu resolute, ubuntu stonking

πŸ’– HTML::TokeParser::Simple::Token::Tag πŸ’–

okay bestie, welcome to the HTML::TokeParser::Simple::Token::Tag page β€” which, if you're squinting at your terminal, is the one the manual calls HTML::...n::Tag(3pm) (the name got squished, it's giving ✨mysterious✨, don't worry about it).


🌸 NAME 🌸

HTML::TokeParser::Simple::Token::Tag β€” it's the token tag class from Token.pm, periodt. πŸ‘‘


✨ SYNOPSIS ✨

no cap, this is how you actually use it:

use HTML::TokeParser::Simple;
my $p = HTML::TokeParser::Simple->new( $somefile );

while ( my $token = $p->get_token ) {
    # This prints all text in an HTML doc (i.e., it strips the HTML)
    next unless $token->is_text;
    print $token->as_is;
}

(that comment in there is literally the original's own words, it's iconic, we keep it πŸ’…)


πŸ¦‹ DESCRIPTION πŸ¦‹

so here's the tea β˜•: this is the base class for start and end tokens. That's its whole job. It's the parent, the main character energy behind the scenes, and it is not supposed to be instantiated. Like, don't. It said what it said. πŸ™ˆ

if you want the actual details, go read HTML::TokeParser::Simple::Token::Tag::Start and HTML::TokeParser::Simple::Token::Tag::End β€” those are the ones doing the real work, fr fr.


πŸ’… OVERRIDDEN METHODS πŸ’…

these are the methods this class hooks you up with. The descriptions of what they actually do live over in HTML::TokeParser::Simple, so slide over there for the deets:

  • as_is β€” it's on the list, bestie 🫢
  • get_tag β€” also on the list πŸ‘‘
  • return_text β€” yep, on the list too ✨

and that's the whole page, no filler, no fluff, we ate and left no crumbs πŸ“

User Contributed Perl Documentation πŸŽ€ β€” that's where this lil' page came from, perl v5.32.1 on 2021-12-05. so like, vintage but still slaying. bye bestie, go parse some HTML πŸ’–πŸŒˆ

πŸ“¦ where this page comes from