PFT::Co...t::Entry(3)
π PFT::Content::Entry π
okay so bestie, welcome to the PFT::Content::Entry page from the User Contributed Perl Documentation β yes it's a Perl manpage, yes it's giving vintage, and yes we're gonna read it together like it's a group chat. pull up a chair π«Ά
β¨ NAME β¨
PFT::Content::Entry β content edited by user. that's it, that's the whole vibe. a file that you touched. main character energy fr π
β¨ SYNOPSIS β¨
use PFT::Content::Entry;
my $p = PFT::Content::Entry->new({
tree => $tree,
path => $path,
name => $name,
})
look at that constructor. so clean. so demure. it takes a tree, a path, and a name, and it just works β¨
β¨ DESCRIPTION β¨
so PFT::Content::Entry is the basetype for all text-based content files. every text-y content thing in this whole system? it's a descendant of this. it's the mother of the group chat. π
it inherits from PFT::Content::File, and it has two specific subtypes that are lowkey its whole personality:
PFT::Content::Blogβ representing an entry with a date πPFT::Content::Pageβ representing an entry without a date π (yes, the original really does spell it "withouth", iconic typo, we love her)
πΈ Methods πΈ
π open
Open the file, and hand you back a file handler. it also sets the binmode according to the locale, because we are respectful of encodings in this house π«Ά
π header
Reads the header from the page.
- Returns
undefif the entry isn't backed by a file (no file, no header, no problem π) - Croaks if the file doesn't contain a healthy header β and ngl, if your header isn't healthy you deserve to hear about it π
π read
Read the page.
- In scalar context it returns an open file descriptor, configured with the correct
binmodeaccording to the header - In list context it returns the header and that same descriptor
- Returns
undefif the file doesn't exist
it croaks if the header is broken. so likeβ¦ don't have a broken header. or do, and get yelled at. your call bestie π
π void
Evaluates as true if the entry is void β meaning the file does not exist, or it contains only the header. empty girlies. header-only girlies. they're all void here β¨
π set_header
Sets a new header, passed by parameter.
heads up: this will rewrite the file. the content will be maintained, so no casualties, but still β it's writing to your file, be normal about it π
π make_consistent
Make the page consistent with the filesystem tree. alignment. harmony. self-care. π
π POD ERRORS π
not me having to tell you this but β hey! the above document had some coding errors, which are explained below:
Around line 43:
=back without =over
yeah. a =back with no =over to back. it's giving orphaned formatting directive. it's giving "who raised you". we still love her though π
okay that's the whole page, you ate that reading session fr fr π
perl v5.42.0 Β· 2025-07-25 Β· from the User Contributed Perl Documentation β this manpage was served fresh on that date and you just devoured it. no cap. periodt. π β¨
π¦ where this page comes from
- fedora 43: perl-PFT 1.4.1-18.fc43 Β· GPL-3.0-or-later
- fedora 44: perl-PFT 1.4.1-18.fc43 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms