StackExchange2/V2/Posts.pm

filter: Statementstmt 61.5% 16 / 26 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 83.3% 5 / 6 Podpod 0.0% 0 / 1 totaltotal 63.6% 21 / 33 CC 1 SCAR 1.5
CC
1
Cov
62%
new
2.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.2
« StackExchange2/V2/Badges.pm ↑ Summary StackExchange2/V2/Comments.pm »
1 package Net::StackExchange2::V2::Posts;
2  
3 1 ▶use 5.006;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 1 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 1 ▶use warnings FATAL => 'all';
Subroutine BEGIN: called CC=1 SCAR=0.0
6 1 ▶use Sub::Name qw(subname);
Subroutine BEGIN: called CC=1 SCAR=0.0
7 1 ▶use Net::StackExchange2::V2::Common qw(query no_params one_param);
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 1 our $VERSION = "0.05";
10  
11 0 ▶sub new {
Subroutine new: not called CC=1 SCAR=6.9
Pod undocumented
12 0 my ($class, $params) = @_;
13 0 my $self = $params;
14 0 bless $self, $class;
15  
16 0 *posts_all = subname(
17 "Net::StackExchange2::V2::Posts::posts_all",
18 no_params("posts"),
19 );
20 0 *posts = subname(
21 "Net::StackExchange2::V2::Posts::posts",
22 one_param("posts"),
23 );
24 0 *posts_comments = subname(
25 "Net::StackExchange2::V2::Posts::posts_comments",
26 one_param("posts", "comments"),
27 );
28 0 *posts_comments_add = subname(
29 "Net::StackExchange2::V2::Posts::posts_comments_add",
30 one_param("posts", "comments/add", {post => 1}),
31 );
32
33 0 *posts_revisions = subname(
34 "Net::StackExchange2::V2::Posts::posts_revisions",
35 one_param("posts", "revisions"),
36 );
37 0 *posts_suggested_edits = subname(
38 "Net::StackExchange2::V2::Posts::posts_suggested_edits",
39 one_param("posts", "suggested-edits"),
40 );
41 0 return $self;
42 }
43 1 1; #END of Net::StackExchange2::V2::Posts
44 __END__
« StackExchange2/V2/Badges.pm ↑ Summary StackExchange2/V2/Comments.pm »