From: Dave Rolsky Date: Mon, 9 Mar 2009 21:16:19 +0000 (-0500) Subject: doc fixes from Radu Greab X-Git-Tag: 0.72_01~81 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=695a379720c6c736a301fa76933543d94754b187;p=gitmo%2FMoose.git doc fixes from Radu Greab --- diff --git a/lib/Moose/Cookbook/Basics/Recipe11.pod b/lib/Moose/Cookbook/Basics/Recipe11.pod index 4c36c80..ecbfc99 100644 --- a/lib/Moose/Cookbook/Basics/Recipe11.pod +++ b/lib/Moose/Cookbook/Basics/Recipe11.pod @@ -89,7 +89,7 @@ The C method is called I the object is constructed, but before it is returned to the caller. The C method provides an opportunity to check the object state as a whole. This is a good place to put logic that cannot be expressed as a type constraint on a single -object. +attribute. In the C class, we need to check the relationship between two attributes, C and C. We throw an exception diff --git a/lib/Moose/Cookbook/Basics/Recipe5.pod b/lib/Moose/Cookbook/Basics/Recipe5.pod index d81b38d..0b22c15 100644 --- a/lib/Moose/Cookbook/Basics/Recipe5.pod +++ b/lib/Moose/Cookbook/Basics/Recipe5.pod @@ -36,7 +36,7 @@ Moose::Cookbook::Basics::Recipe5 - More subtypes, coercion in a B class => from 'HashRef' => via { HTTP::Headers->new( %{$_} ) }; - subtype 'My.URI' => as class_type('HTTP::Headers'); + subtype 'My.URI' => as class_type('URI'); coerce 'My.URI' => from 'Object' @@ -150,7 +150,7 @@ help implement coercions. In this case we use L. Once again, we need to declare a class type for our non-Moose L class: - subtype 'My.URI' => as class_type('HTTP::Headers'); + subtype 'My.URI' => as class_type('URI'); Then we define the coercion: diff --git a/lib/Moose/Cookbook/Roles/Recipe1.pod b/lib/Moose/Cookbook/Roles/Recipe1.pod index 7478c19..7b140f9 100644 --- a/lib/Moose/Cookbook/Roles/Recipe1.pod +++ b/lib/Moose/Cookbook/Roles/Recipe1.pod @@ -78,7 +78,7 @@ reuse. This recipe demonstrates the latter, with roles that define comparison and display code for objects. Let's start with C. First, note that we've replaced C -with C. We also have a new sugar function, C: +with C. We also have a new sugar function, C: requires 'equal_to';