summary refs log tree commit diff
diff options
context:
space:
mode:
authorfranck cuny <franck@lumberjaph.net>2010-02-10 14:09:44 +0100
committerfranck cuny <franck@lumberjaph.net>2010-02-10 14:09:44 +0100
commitf5063c7276c443609f415d627eaf8b8776daa356 (patch)
treeb92108b66b7048764ddc84f069c21bffa5485f30
parentmeta class, with private and protected roles (diff)
downloadmoosex-privacy-f5063c7276c443609f415d627eaf8b8776daa356.tar.gz
meta class, with private and protected roles
-rw-r--r--lib/MooseX/Privacy/Meta/Class.pm17
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/MooseX/Privacy/Meta/Class.pm b/lib/MooseX/Privacy/Meta/Class.pm
new file mode 100644
index 0000000..495d09d
--- /dev/null
+++ b/lib/MooseX/Privacy/Meta/Class.pm
@@ -0,0 +1,17 @@
+package MooseX::Privacy::Meta::Class;
+
+use Moose::Role;
+use Moose::Meta::Class;
+
+with qw/MooseX::Privacy::Meta::Class::Private
+    MooseX::Privacy::Meta::Class::Protected/;
+
+sub _build_meta_class {
+    my $self = shift;
+    return Moose::Meta::Class->create_anon_class(
+        superclasses => [ $self->method_metaclass ],
+        cache        => 1,
+    );
+}
+
+1;