MooseX...:Moose(3pm)
π MooseX::Types::Moose(3pm) β the vibe check
okay bestie, so this is a page from the User Contributed Perl Documentation section of the manual, and it's literally the glow-up guide for MooseX::Types::Moose. Pull up a chair π
πΈ NAME πΈ
MooseX::Types::Moose β type exports that match the types shipped with Moose. no cap, that's the whole thing β¨
π¦ VERSION π¦
version 0.51 β yes she's numbered, yes she's iconic π
π SYNOPSIS π
okay so here's how you actually use her, look:
package Foo;
use Moose;
use MooseX::Types::Moose qw( ArrayRef Int Str );
use Carp qw( croak );
has 'name',
is => 'rw',
isa => Str;
has 'ids',
is => 'rw',
isa => ArrayRef[Int];
sub add {
my ($self, $x, $y) = @_;
croak 'First arg not an Int' unless is_Int($x);
croak 'Second arg not an Int' unless is_Int($y);
return $x + $y;
}
1;
likeβ¦ she's giving "I type-check my friends before I let them into the function" π and honestly? valid.
β¨ DESCRIPTION β¨
So this package is basically a virtual library for MooseX::Types β and what she does is she's able to export, like, all the types known to Moose. every single one. obsessed. π«Ά
If you wanna know the general usage info (the how-to, the etiquette, the lore), go peek at MooseX::Types. that's where the general stuff lives, iykyk.
π₯ METHODS π₯
π type_storage
She overrides MooseX::Types::Base's "type_storage" so that it hands you back a hash reference containing all the built-in Moose types. that's it. that's the method. and she ate. π
π SEE ALSO π
MooseMoose::Util::TypeConstraints
like, go read your friends too, they're relevant π¦
π SUPPORT π
Bugs may be submitted through the RT bug tracker https://rt.cpan.org/Public/Dist/Display.html?Name=MooseX-Types (or bug-MooseX-Types@rt.cpan.org β yes that's an email, mailto link and all: bug-MooseX-Types@rt.cpan.org).
There's also a mailing list for users of this distribution, chilling at http://lists.perl.org/list/moose.html πΈ
And there's an irc channel for users of this distribution too, at "#moose" on "irc.perl.org" β irc://irc.perl.org/#moose. come say hi, the vibes are immaculate π§
π AUTHOR π
Robert "phaylon" Sedlacek <rs@474.at> β king behaviour, honestly π
π COPYRIGHT AND LICENCE π
This software is copyright (c) 2007 by Robert "phaylon" Sedlacek.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. π
like, free as in freedom, bestie β go wild (but like, within the licence terms, fr fr).
mwah π that's the whole page! brought to you by perl v5.42.0, dated 2025-07-25, and it's MooseX::Types::Moose(3pm) all the way down. stay type-safe, stay slay β¨π¦π
π¦ where this page comes from
- fedora 43: perl-MooseX-Types 0.51-2.fc43 Β· GPL-1.0-or-later OR Artistic-1.0-Perl
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms