Net::H...stItem(3pm)

πŸ’– NAME πŸ’–

Net::Hotline::FileListItem β€” it's a File object, bestie, and it's used internally by Net::Hotline::Client. That's the whole vibe. ✨


🌸 SYNOPSIS 🌸

okay so here's how you'd actually touch this thing:

use Net::Hotline::FileListItem;

$file = new Net::Hotline::FileListItem;

$file->name("foo.txt");
$file->type("TEXT");
...

like. that's it. that's the whole flex. πŸ’…


πŸ¦‹ DESCRIPTION πŸ¦‹

Net::Hotline::FileListItem is a simple class β€” lowercase simple, no drama β€” for storing and retrieving file information. πŸŽ€

bestie listen: you should never have to create your own Net::Hotline::FileListItem objects when you're using Net::Hotline::Client. Never ever. That's not your job, that's the module's job, and the module is handling it. 🫢

Getting attributes is basically the whole point. Setting them is to a lesser extent necessary. That's it. That's the entire to-do list. ✨


🧚 CONSTRUCTION 🧚

  • new β€” creates a brand new Net::Hotline::FileListItem object, and every single attribute starts out as undef. (well β€” the numeric ones start at zero instead, because numbers can't be undef and slay at the same time.) 🌈

πŸ‘‘ METHODS πŸ‘‘

okay so ALL the Net::Hotline::FileListItem methods are just simple attribute get/set routines. No cap. Every single one.

The rules, fr fr:

  • if you give it an argument, it sets that attribute
  • in all cases, it returns the current value of the attribute 🌟

so basically every method is a two-for-one. iconic behaviour honestly.

πŸ“ creator TEXT

The file creator β€” and it's given as a four-letter Mac OS creator code. Like "TTXT", "SIT!", etc. ✨

πŸŽ€ name TEXT

The file name. That's it. That's the whole description. short and sweet, main character energy. πŸ’…

πŸ’œ size NUM

The size of the file, in bytes. NUM, not TEXT, bestie β€” it's a number. πŸ”’

⭐ type TEXT

The file type β€” given as a four-letter Mac OS type code, like "TEXT", "PICT", etc. β€” or Net::Hotline::Constants::HTLC_FOLDER_TYPE if the thing is a folder. πŸ“ (yes folders get to play too.)


🌈 AUTHOR 🌈

John C. Siracusa (siracusa@mindspring.com) β€” we love a legend. πŸ‘‘


Copyright(c) 1999 by John Siracusa. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. 🫢


and that's the tea, bestie β€” this page came to you from perl v5.32.0, dated 2021-01-09, and it's part of the User Contributed Perl Documentation, iykyk. mwah. πŸ’‹βœ¨

πŸ“¦ where this page comes from