File Coverage

blib/lib/LaTeX/TikZ/Point/Math/Complex.pm
Criterion Covered Total %
statement 15 15 100.0
branch n/a
condition n/a
subroutine 5 5 100.0
pod n/a
total 20 20 100.0


line stmt bran cond sub pod time code
1             package LaTeX::TikZ::Point::Math::Complex;
2              
3 3     3   5672 use strict;
  3         9  
  3         195  
4 3     3   18 use warnings;
  3         7  
  3         260  
5              
6             =head1 NAME
7              
8             LaTeX::TikZ::Point::Math::Complex - Coerce Math::Complex points into LaTeX::TikZ::Point objects.
9              
10             =head1 VERSION
11              
12             Version 0.02
13              
14             =cut
15              
16             our $VERSION = '0.02';
17              
18 3     3   28 use Math::Complex;
  3         8  
  3         1047  
19              
20 3     3   23 use LaTeX::TikZ::Point;
  3         8  
  3         127  
21              
22 3         156 use Any::Moose 'Util::TypeConstraints' => [ qw/
23             class_type
24             coerce
25             from
26             via
27 3     3   23 / ];
  3         6  
28              
29             my $mc_tc = class_type 'Math::Complex';
30              
31             coerce 'LaTeX::TikZ::Point::Autocoerce'
32             => from 'Math::Complex'
33             => via { LaTeX::TikZ::Point->new(x => $_->Re, y => $_->Im); };
34              
35             =head1 AUTHOR
36              
37             Vincent Pit, C<< <perl at profvince.com> >>, L<http://www.profvince.com>.
38              
39             You can contact me by mail or on C<irc.perl.org> (vincent).
40              
41             =head1 BUGS
42              
43             Please report any bugs or feature requests to C<bug-latex-tikz at rt.cpan.org>, or through the web interface at L<http://rt.cpan.org/NoAuth/ReportBug.html?Queue=LaTeX-TikZ>.
44             I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
45              
46             =head1 SUPPORT
47              
48             You can find documentation for this module with the perldoc command.
49              
50             perldoc LaTeX::TikZ
51              
52             =head1 COPYRIGHT & LICENSE
53              
54             Copyright 2010 Vincent Pit, all rights reserved.
55              
56             This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
57              
58             =cut
59              
60             1; # End of LaTeX::TikZ::Point::Math::Complex