Net::FT...eHandle(3)

πŸ“¦
version 1.125 Β· 2 versions
, in fedora 43

πŸ’– NAME πŸ’–

okay bestie, welcome to Net::FTPServer::Full::FileHandle β€” it's literally the full FTP server personality ✨ and yes, the manual name is Net::FT...eHandle(3) (User Contributed Perl Documentation, iykyk). This is the file-handle girlie that the full FTP server personality rides with. She handles your files, your dirs, your links, your whole vibe. πŸŽ€


✨ SYNOPSIS ✨

use Net::FTPServer::Full::FileHandle;

that's it. that's the whole intro. she's lowkey easy like that πŸ’…


πŸ¦‹ METHODS πŸ¦‹

  • $dirh = $fileh->dir β€” gives you back the directory that's holding this file. like, who's your parent dir bestie? 🫢
  • $fh = $fileh->open (["r"|"w"|"a"]) β€” opens a file handle in either read or write mode. it's derived from IO::Handle, so if you wanna know the lore, go read IO::Handle(3). no cap. πŸ“–
  • ($mode, $perms, $nlink, $user, $group, $size, $time) = $handle->status β€” returns the file or directory status, and the fields it hands back are:
  $mode     Mode        'd' = directory,
                        'f' = file,
                        and others as with
                        the find(1) -type option.
  $perms    Permissions Permissions in normal octal numeric format.
  $nlink    Link count
  $user     Username    In printable format.
  $group    Group name  In printable format.
  $size     Size        File size in bytes.
  $time     Time        Time (usually mtime) in Unix time_t format.
bestie, real talk: in derived classes some of this status info may well be synthesized, because virtual filesystems will often not contain information in a Unix-like format. so don't be shocked when the numbers are giving "made up" instead of "straight off the disk". 😭
  • $rv = $handle->move ($dirh, $filename) β€” moves the current file (or directory) into directory $dirh and calls it $filename. if the operation slays, return 0; if it flops, return -1. ✨
heads up though β€” underlying filesystems may impose limitations on moves. for example: it may not be possible to move a directory; it may not be possible to move a file to another directory; it may not be possible to move a file across filesystems. so like, vibe check before you yank things around. πŸ’€
  • $rv = $fileh->delete β€” deletes the current file. if the delete command was successful, return 0; else if there was an error, return -1. gone, girl. πŸ—‘οΈ
  • $link = $fileh->readlink β€” if the current file is really a symbolic link, this reads the contents of the link and returns it. she's not what she seems, and that's the point. πŸ”—

πŸ‘‘ AUTHORS πŸ‘‘

Richard Jones (rich@annexia.org). iconic. πŸ’œ


Copyright (C) 2000 Biblio@Tech Ltd., Unit 2-3, 50 Carnwath Road, London, SW6 3EG, UK


🌈 SEE ALSO 🌈


and that's the whole page bestie, no crumbs left πŸ“ β€” this was perl v5.42.0, dated 2025-07-25, brought to you by the Net::FT...eHandle(3) girlies. periodt. πŸ’…βœ¨

πŸ“¦ where this page comes from