Class:...String(3pm)
π Class:...String(3pm) β the manual page, but make it cute π
okay so bestie, welcome to Class::Meta::Types::String π β the Perl doc you're reading is filed under the manual name Class:...String(3pm), and honestly? it's giving short-but-iconic. let's get into it π
β¨ NAME β¨
Class::Meta::Types::String β string data types, periodt π§΅β¨
πΈ SYNOPSIS πΈ
okay so here's the whole vibe, copy it exactly bestie:
package MyApp::Thingy;
use strict;
use Class::Meta;
use Class::Meta::Types::String;
# OR...
# use Class::Meta::Types::String 'affordance';
# OR...
# use Class::Meta::Types::String 'semi-affordance';
BEGIN {
# Create a Class::Meta object for this class.
my $cm = Class::Meta->new( key => 'thingy' );
# Add a string attribute.
$cm->add_attribute( name => 'name',
type => 'string' );
$cm->build;
}
see those # OR... lines? you can load it plain, or load it with 'affordance', or with 'semi-affordance'. all three are valid, no cap π
π DESCRIPTION π
This module provides a string data type for use with Class::Meta attributes. literally that's its whole job and it ate π
So the way that you use it: simply load it, then pass "string" to the add_attribute() method of a Class::Meta object, and boom β you've created an attribute of the string data type. main character energy fr fr β¨
if you wanna know more about using and creating data types, go check out Class::Meta::Type. iykyk π¦
π«Ά SUPPORT π«Ά
This module is stored in an open GitHub repository <http://github.com/theory/class-meta/>. feel free to fork and contribute bestie, we love a collab π
Please file bug reports via GitHub Issues <http://github.com/theory/class-meta/issues/> or by sending mail to bug-Class-Meta@rt.cpan.org <mailto:bug-Class-Meta@rt.cpan.org> π¬ (not me being emotionally available for bug reports π)
π AUTHOR π
David E. Wheeler <david@justatheory.com> β icon behavior, we stan π
π SEE ALSO π
Other classes of interest within the Class::Meta distribution include:
Class::Metaβ This class contains most of the documentation you need to get started withClass::Meta. the starter pack, basically πClass::Meta::Typeβ This class manages the creation of data types. the type-maker π§Class::Meta::Attributeβ This class managesClass::Metaclass attributes, all of which are based on data types. everything's downstream of types, lowkey π₯
Other data type modules:
Class::Meta::Types::PerlClass::Meta::Types::BooleanClass::Meta::Types::Numeric
the whole squad, together π«
π COPYRIGHT AND LICENSE π
Copyright (c) 2002-2011, David E. Wheeler. Some Rights Reserved. (yes, "some" β not all, slay π )
This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. πͺ
fr fr: if you're reusing this, keep that copyright and license line intact. no skipping, bestie π
okay that's the whole page!! π this was rendered from the perl v5.34.0 release, dated 2022-06-11, and the manual title on the tin is Class:...String(3pm) β go forth and string-attribute responsibly, you absolute legend π¦β¨πΈ
π¦ where this page comes from
- debian bookworm: libclass-meta-perl 0.66-3 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- debian trixie: libclass-meta-perl 0.66-3 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libclass-meta-perl 0.66-3 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms