Places/Review/Aspect.pm

filter: Statementstmt 82.6% 19 / 23 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 62.5% 5 / 8 Podpod 0.0% 0 / 1 totaltotal 75.0% 24 / 32 SCAR 0.1
CC
1
Cov
83%
as_string
2.0
__ANON__
1.1
__ANON__
1.1
CRAP 1.0
« Places/Location.pm ↑ Summary
1 package WWW::Google::Places::Review::Aspect;
2  
3 8 $WWW::Google::Places::Review::Aspect::VERSION = '0.35';
4 8 $WWW::Google::Places::Review::Aspect::AUTHORITY = 'cpan:MANWAR';
5  
6 =head1 NAME
7  
8 WWW::Google::Places::Review::Aspect - Represent 'review aspect' of place.
9  
10 =head1 VERSION
11  
12 Version 0.35
13  
14 =cut
15  
16 8 ▶use 5.006;
Subroutine BEGIN: called CC=1 SCAR=0.0
17 8 ▶use Data::Dumper;
Subroutine BEGIN: called CC=1 SCAR=0.0
18  
19 8 ▶use Moo;
Subroutine BEGIN: called CC=1 SCAR=0.0
20 8 ▶use namespace::clean;
Subroutine BEGIN: called CC=1 SCAR=0.0
21  
22 8 ▶use overload q{""} => 'as_string', fallback => 1;
Subroutine BEGIN: called CC=1 SCAR=0.0
23  
24 0 ▶has 'rating' => (is => 'ro', default => sub { 'N/A' });
Subroutine __ANON__: not called CC=1 SCAR=1.2
25 0 ▶has 'type' => (is => 'ro', default => sub { 'N/A' });
Subroutine __ANON__: not called CC=1 SCAR=1.2
26  
27 =head1 METHODS
28  
29 =head2 rating()
30  
31 Returns aspects rating.
32  
33 =head2 type()
34  
35 Returns aspects type.
36  
37 =cut
38  
39 sub as_string {
40 0 ▶ my ($self) = @_;
Subroutine as_string: not called CC=1 SCAR=6.9
Pod undocumented
41  
42 0 return sprintf("Type: %s, Rating: %s", $self->type, $self->rating);
43 }
44  
45 =head1 AUTHOR
46  
47 Mohammad S Anwar, C<< <mohammad.anwar at yahoo.com> >>
48  
49 =head1 REPOSITORY
50  
51 L<https://github.com/manwar/WWW-Google-Places>
52  
53 =head1 BUGS
54  
55 Please report any bugs or feature requests to C<bug-www-google-places at rt.cpan.org>,
56 or through the web interface at L<http://rt.cpan.org/NoAuth/ReportBug.html?Queue=WWW-Google-Places>.
57 I will be notified, and then you'll automatically be notified of progress on your
58 bug as I make changes.
59  
60 =head1 SUPPORT
61  
62 You can find documentation for this module with the perldoc command.
63  
64 perldoc WWW::Google::Places::Review::Aspect
65  
66 You can also look for information at:
67  
68 =over 4
69  
70 =item * RT: CPAN's request tracker (report bugs here)
71  
72 L<http://rt.cpan.org/NoAuth/Bugs.html?Dist=WWW-Google-Places>
73  
74 =item * AnnoCPAN: Annotated CPAN documentation
75  
76 L<http://annocpan.org/dist/WWW-Google-Places>
77  
78 =item * CPAN Ratings
79  
80 L<http://cpanratings.perl.org/d/WWW-Google-Places>
81  
82 =item * Search CPAN
83  
84 L<http://search.cpan.org/dist/WWW-Google-Places/>
85  
86 =back
87  
88 =head1 LICENSE AND COPYRIGHT
89  
90 Copyright (C) 2011 - 2016 Mohammad S Anwar.
91  
92 This program is free software; you can redistribute it and / or modify it under
93 the terms of the the Artistic License (2.0). You may obtain a copy of the full
94 license at:
95  
96 L<http://www.perlfoundation.org/artistic_license_2_0>
97  
98 Any use, modification, and distribution of the Standard or Modified Versions is
99 governed by this Artistic License.By using, modifying or distributing the Package,
100 you accept this license. Do not use, modify, or distribute the Package, if you do
101 not accept this license.
102  
103 If your Modified Version has been derived from a Modified Version made by someone
104 other than you,you are nevertheless required to ensure that your Modified Version
105 complies with the requirements of this license.
106  
107 This license does not grant you the right to use any trademark, service mark,
108 tradename, or logo of the Copyright Holder.
109  
110 This license includes the non-exclusive, worldwide, free-of-charge patent license
111 to make, have made, use, offer to sell, sell, import and otherwise transfer the
112 Package with respect to any patent claims licensable by the Copyright Holder that
113 are necessarily infringed by the Package. If you institute patent litigation
114 (including a cross-claim or counterclaim) against any party alleging that the
115 Package constitutes direct or contributory patent infringement,then this Artistic
116 License to you shall terminate on the date that such litigation is filed.
117  
118 Disclaimer of Warranty: THE PACKAGE IS PROVIDED BY THE COPYRIGHT HOLDER AND
119 CONTRIBUTORS "AS IS' AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES. THE IMPLIED
120 WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
121 NON-INFRINGEMENT ARE DISCLAIMED TO THE EXTENT PERMITTED BY YOUR LOCAL LAW. UNLESS
122 REQUIRED BY LAW, NO COPYRIGHT HOLDER OR CONTRIBUTOR WILL BE LIABLE FOR ANY DIRECT,
123 INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING IN ANY WAY OUT OF THE USE
124 OF THE PACKAGE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
125  
126 =cut
127  
128 8 1; # End of WWW::Google::Places::Review::Aspect
« Places/Location.pm ↑ Summary