Jozef Kutej > Chart-OFC2-0.07 > Chart::OFC2::Types

Download:
Chart-OFC2-0.07.tar.gz

Dependencies

Annotate this POD

CPAN RT

Open  0
View/Report Bugs
Source   Latest Release: Chart-OFC2-0.08_02

NAME ^

Chart::OFC2::Types - constrainted types and coercions for Chart::OFC2

SYNOPSIS ^

package Chart::OFC2::Demo;

use Moose; use Chart::OFC2::Types qw( PositiveInt ChartOFC2Labels );

has 'attribute1' => ( is => 'rw', isa => PositiveInt, ); has 'attribute2' => ( is => 'rw', isa => ChartOFC2Labels, coerce => 1 );

1;

use Chart::OFC2::Demo; my $demo = Chart::OFC2::Demo->new({ attribute1 => 4, attribute2 => { labels => [ "Jan", "Feb", "Mar", "Apr", "May" ] } });

TYPES ^

PositiveInt

An integer greater than 0

ChartOFC2Labels

subtype of Chart::OFC2::Labels

Coerces from HashRef via "new" in Chart::OFC2::Labels

AUTHOR ^

Jeff Tam

syntax highlighting: