MooseX...O::File(3pm)

πŸ“¦
version 0.53 Β· 5 versions
, in ubuntu noble, ubuntu resolute, ubuntu stonking

πŸ’– NAME πŸ’–

MooseX::Storage::IO::File β€” a whole entire basic File I/O role, bestie. That's it, that's the gig. It's the lil' plugin that lets your Moose classes save themselves to disk and load themselves back, no cap. πŸŽ€

Oh and hey, if you're staring at the manpage header going "what is MooseX...O::File??" β€” that's just the truncated terminal title, it's the User Contributed Perl Documentation version of this page. The actual module is the full name up there. πŸ’…


✨ VERSION ✨

version 0.53</p> πŸ¦‹ (iconic, vintage, we love a little time capsule)


🌸 SYNOPSIS 🌸

okay so like. here's the whole vibe. you with the role, you get store and load, and your object can just. exist on your filesystem. main character energy fr fr:

package Point;
use Moose;
use MooseX::Storage;

with Storage('format' => 'JSON', 'io' => 'File');

has 'x' => (is => 'rw', isa => 'Int');
has 'y' => (is => 'rw', isa => 'Int');

1;

my $p = Point->new(x => 10, y => 10);

## methods to load/store a class
## on the file system

$p->store('my_point.json');

my $p2 = Point->load('my_point.json');

note the little ## comments up there β€” those are straight from the original, I'm not touching them, they're part of the lore. πŸ’œ


🫢 METHODS 🫢

two methods. that's it. two. and they carry this whole module on their backs, obsessed with them honestly. 😭

  • load ($filename) β€” pull a whole object back up out of a file. You hand it a filename, it hands you your class back. resurrection but make it Perl. 🌈
  • store ($filename) β€” write your object down into a file. You hand it a filename, it goes and saves itself there. bye bestie, see you on disk. πŸ’Ύβœ¨

πŸ¦‹ SUPPORT πŸ¦‹

found a bug? yeah it happens, don't panic, we got you πŸ’–

fr fr come say hi in #moose, the people there are genuinely so nice and they know EVERYTHING πŸ’…

πŸ‘‘ AUTHORS πŸ‘‘

give it up for the originators, the founding mothers/fathers of this whole thing, absolute legends, no notes πŸŽ€

  • Chris Prather <chris.prather@iinteractive.com>
  • Stevan Little <stevan.little@iinteractive.com>
  • Χ™Χ•Χ‘Χœ Χ§Χ•Χ’'מן (Yuval Kogman) <nothingmuch@woobling.org>

This software is copyright (c) 2007 by Infinity Interactive, Inc. 2007!! a whole legend ✨

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. free as in go wild, just respect the Perl 5 terms, okay? periodt. πŸ’š


okay that's the page bestie, you're officially educated, go store something πŸ’–

sign-off time: this was perl v5.36.0, dated 2022-10-16, and the manpage title it lives under is MooseX...O::File(3pm) β€” because terminal headers have zero chill and truncate everything. mwah. πŸ’‹πŸ’…

πŸ“¦ where this page comes from