From: Dave Rolsky Date: Sat, 2 Aug 2008 02:52:02 +0000 (+0000) Subject: Fix references to previous recipe X-Git-Tag: 0_55~18 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=09412052a828a0e27d8fb1cbd64feb1325994b62;p=gitmo%2FMoose.git Fix references to previous recipe --- diff --git a/lib/Moose/Cookbook/Meta/Recipe3.pod b/lib/Moose/Cookbook/Meta/Recipe3.pod index 329a410..1faeaca 100644 --- a/lib/Moose/Cookbook/Meta/Recipe3.pod +++ b/lib/Moose/Cookbook/Meta/Recipe3.pod @@ -64,18 +64,19 @@ Moose::Cookbook::Meta::Recipe3 - Labels implemented via attribute traits =head1 BUT FIRST -This recipe is a continuation of L. Please read that -first. +This recipe is a continuation of +L. Please read that recipe first. =head1 MOTIVATION -In Recipe 21, we created an attribute metaclass that gives attributes a "label" -that can be set in L. That works well until you want a second -meta-attribute, or until you want to adjust the behavior of the attribute. You -could define a specialized attribute metaclass to use in every attribute. -However, you may want different attributes to have different behaviors. You -might end up with a unique attribute metaclass for B, -with a lot of code copying and pasting! +In L, we created an attribute +metaclass that gives attributes a "label" that can be set in +L. That works well until you want a second meta-attribute, +or until you want to adjust the behavior of the attribute. You could +define a specialized attribute metaclass to use in every attribute. +However, you may want different attributes to have different +behaviors. You might end up with a unique attribute metaclass for +B, with a lot of code copying and pasting! Or, if you've been drinking deeply of the Moose kool-aid, you'll have a role for each of the behaviors. One role would give a label meta-attribute. Another @@ -105,7 +106,7 @@ user-level class. =head1 DISSECTION -A side-by-side look of the code examples in this recipe and recipe 21 should +A side-by-side look of the code examples in this recipe and recipe 2 should indicate that defining and using a trait is very similar to defining and using a new attribute metaclass. @@ -132,7 +133,7 @@ C to find the full name of the trait. Now we begin writing our application logic. I'll only cover what has changed -since recipe 21. +since recipe 2. has url => ( traits => [qw/Labeled/],