2011-06-27 16:13:31 -04:00
|
|
|
# #!/usr/bin/perl
|
|
|
|
|
|
|
|
# Moose package
|
|
|
|
snippet moosecl
|
|
|
|
package ${1:ClassName};
|
|
|
|
|
|
|
|
use Moose;
|
|
|
|
#extends ${2:# ParentClass};
|
|
|
|
|
|
|
|
${6:# body of class}
|
|
|
|
|
2011-06-27 16:38:45 -04:00
|
|
|
1;
|
|
|
|
|
2011-06-27 16:32:23 -04:00
|
|
|
|
2011-06-27 16:13:31 -04:00
|
|
|
__END__
|
|
|
|
|
|
|
|
=head1 NAME
|
|
|
|
|
|
|
|
$1 - ${3:ShortDesc}
|
|
|
|
|
|
|
|
=head1 SYNOPSIS
|
|
|
|
|
|
|
|
${4:# synopsis...}
|
|
|
|
|
|
|
|
=head1 DESCRIPTION
|
|
|
|
|
|
|
|
${5:# longer description...}
|
|
|
|
|
|
|
|
|
|
|
|
# has
|
|
|
|
snippet has
|
|
|
|
has ${1:attribute} => ( #{{{
|
|
|
|
is => '${2:ro|rw}',
|
|
|
|
isa => '${3:Str|Int|HashRef|ArrayRef|etc}',
|
|
|
|
default => ${4:defaultvalue}
|
|
|
|
,${5:# other attributes}
|
|
|
|
); #}}}
|
|
|
|
|
|
|
|
|
2011-06-27 16:32:23 -04:00
|
|
|
# override
|
|
|
|
snippet override
|
|
|
|
override ${1:attribute} => sub { #{{{
|
|
|
|
${2:# my $self = shift;};
|
|
|
|
${3:# my ($self,$args) = @_;};
|
|
|
|
}; #}}}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|