Skip to content

Instantly share code, notes, and snippets.

use MooseX::Declare;
class MyClass {
method mymethod(Str $aaa) {
return $aaa;
}
}
my $aaa = MyClass->new;
warn $aaa->mymethod(['aaa']);
use Android;
my $a = Android->new();
use Plack::Runner;
use Plack::Request;
my $runner = Plack::Runner->new;
$runner->parse_options(qw[
--server HTTP::Server::PSGI
--port 8888
]);
use Moose::Util::TypeConstraints;
use MooseX::Params::Validate;
subtype 'Filename' => as 'Str' => where { -x $_ };
sub foo {
my ($name) = pos_validated_list( \@_, { isa => 'Filename' } );
print "Houston, we have a filename: $name \n";
}
@stevan
stevan / gist:180984
Created September 4, 2009 16:43 — forked from jshirley/gist:180597
use Data::Verifier;
use DateTimeX::Easy;
use MooseX::Types::DateTime qw(TimeZone DateTime);
use MooseX::Types::Moose qw/Str/;
use MooseX::Types;
use feature ':5.10';
my $verifier = Data::Verifier->new(
filters => [ qw(trim) ],

Moose Hackathon Agenda

This is a list of topics/ideas/wishes/dreams that we will discuss during the Moose hackathon at YAPC::NA this year. They are in no particular order, nor does inclusion of this list imply any type of endorsement of the idea, these are just ideas, so please feel free to add yours in.


  • Traits/Roles in Class::MOP
    • A low-level trait/role type primitive
  • removing Test::Exception from Moose/MOP
package MyRole;
...
package MyBaseThing;
with MyRole;
....