[Bps-public-commit] r16917 - in Path-Dispatcher/trunk: lib/Path/Dispatcher

sartak at bestpractical.com sartak at bestpractical.com
Tue Nov 18 19:57:43 EST 2008


Author: sartak
Date: Tue Nov 18 19:57:42 2008
New Revision: 16917

Modified:
   Path-Dispatcher/trunk/   (props changed)
   Path-Dispatcher/trunk/lib/Path/Dispatcher/Path.pm

Log:
 r75785 at onn:  sartak | 2008-11-18 19:57:39 -0500
 Path->get_metadata (which can be overridden by subclasses!)


Modified: Path-Dispatcher/trunk/lib/Path/Dispatcher/Path.pm
==============================================================================
--- Path-Dispatcher/trunk/lib/Path/Dispatcher/Path.pm	(original)
+++ Path-Dispatcher/trunk/lib/Path/Dispatcher/Path.pm	Tue Nov 18 19:57:42 2008
@@ -1,6 +1,7 @@
 #!/usr/bin/env perl
 package Path::Dispatcher::Path;
 use Moose;
+use MooseX::AttributeHelpers;
 
 has path => (
     is        => 'rw',
@@ -9,9 +10,13 @@
 );
 
 has metadata => (
+    metaclass => 'Collection::Hash',
     is        => 'rw',
     isa       => 'HashRef',
     predicate => 'has_metadata',
+    provides  => {
+        get => 'get_metadata',
+    },
 );
 
 # allow Path::Dispatcher::Path->new($path)



More information about the Bps-public-commit mailing list