.\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.42) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "MooseX::AttributeShortcuts::Trait::Role::Attribute 3pm" .TH MooseX::AttributeShortcuts::Trait::Role::Attribute 3pm "2022-06-15" "perl v5.34.0" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" MooseX::AttributeShortcuts::Trait::Role::Attribute \- Role attribute trait to create builder method .SH "VERSION" .IX Header "VERSION" This document describes version 0.037 of MooseX::AttributeShortcuts::Trait::Role::Attribute \- released November 20, 2017 as part of MooseX-AttributeShortcuts. .SH "DESCRIPTION" .IX Header "DESCRIPTION" Normally, attribute options processing takes place at the time an attribute is created and attached to a class, either by virtue of a \f(CW\*(C`has\*(C'\fR statement in a class definition or when a role is applied to a class. .PP This is not an optimal approach for inline builder methods. .PP This is a role attribute trait, to create builder methods when role attributes are created, so that they can be aliased, excluded, etc, like any other role method. .SH "ROLE PARAMETERS" .IX Header "ROLE PARAMETERS" Parameterized roles accept parameters that influence their construction. This role accepts the following parameters. .SS "builder_prefix" .IX Subsection "builder_prefix" .SH "AROUND METHOD MODIFIERS" .IX Header "AROUND METHOD MODIFIERS" .SS "new" .IX Subsection "new" If we have an inline builder defined in our role options, swizzle our options such that \f(CW\*(C`builder\*(C'\fR becomes the builder method name, and \f(CW\*(C`anon_builder\*(C'\fR is the anonymous sub. .SH "AFTER METHOD MODIFIERS" .IX Header "AFTER METHOD MODIFIERS" .SS "attach_to_role" .IX Subsection "attach_to_role" If we have an inline builder defined in our role options, install it as a method. .SH "METHODS" .IX Header "METHODS" .SS "\fBbuilder_method_metaclass()\fP" .IX Subsection "builder_method_metaclass()" Returns the metaclass we'll use to install a inline builder. .SH "SEE ALSO" .IX Header "SEE ALSO" Please see those modules/websites for more information related to this module. .IP "\(bu" 4 MooseX::AttributeShortcuts .SH "BUGS" .IX Header "BUGS" Please report any bugs or feature requests on the bugtracker website .PP When submitting a bug or request, please include a test-file or a patch to an existing test-file that illustrates the bug or desired feature. .SH "AUTHOR" .IX Header "AUTHOR" Chris Weyl .SH "COPYRIGHT AND LICENSE" .IX Header "COPYRIGHT AND LICENSE" This software is Copyright (c) 2017, 2015, 2014, 2013, 2012, 2011 by Chris Weyl. .PP This is free software, licensed under: .PP .Vb 1 \& The GNU Lesser General Public License, Version 2.1, February 1999 .Ve