Mattermost/V4/API/Object/Channel/Member.pm

filter: Statementstmt 64.0% 16 / 25 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 22.2% 2 / 9 Podpod n/a totaltotal 52.9% 18 / 34 CC 1 SCAR 5.8
CC
1
Cov
64%
_build_notify_props
2.0
_build_last_update_at
2.0
_build_last_viewed_at
2.0
CRAP 1.8
« Mattermost/V4/API/Object/Job.pm ↑ Summary Mattermost/V4/API/Resource/Webhook/Incoming.pm »
1 package WebService::Mattermost::V4::API::Object::Channel::Member;
2  
3 # ABSTRACT: A channel member item.
4  
5 12 ▶use Moo;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 12 ▶use Types::Standard qw(HashRef InstanceOf Int Maybe Str);
Subroutine BEGIN: called CC=1 SCAR=0.0
7  
8 12 extends 'WebService::Mattermost::V4::API::Object';
9 12 with qw(
10 WebService::Mattermost::V4::API::Object::Role::BelongingToUser
11 WebService::Mattermost::V4::API::Object::Role::BelongingToChannel
12 WebService::Mattermost::V4::API::Object::Role::Roles
13 );
14  
15 ################################################################################
16  
17 12 has notify_props => (is => 'ro', isa => Maybe[HashRef], lazy => 1, builder => 1);
18 12 has last_update_at => (is => 'ro', isa => Maybe[Int], lazy => 1, builder => 1);
19 12 has last_viewed_at => (is => 'ro', isa => Maybe[Int], lazy => 1, builder => 1);
20 12 has mention_count => (is => 'ro', isa => Maybe[Int], lazy => 1, builder => 1);
21 12 has msg_count => (is => 'ro', isa => Maybe[Int], lazy => 1, builder => 1);
22 12 has last_update => (is => 'ro', isa => Maybe[InstanceOf['DateTime']], lazy => 1, builder => 1);
23 12 has last_viewed => (is => 'ro', isa => Maybe[InstanceOf['DateTime']], lazy => 1, builder => 1);
24  
25 ################################################################################
26  
27 0 ▶sub _build_notify_props { shift->raw_data->{notify_props} }
Subroutine _build_notify_props: not called CC=1 SCAR=6.9
28 0 ▶sub _build_last_update_at { shift->raw_data->{last_update_at} }
Subroutine _build_last_update_at: not called CC=1 SCAR=6.9
29 0 ▶sub _build_last_viewed_at { shift->raw_data->{last_viewed_at} }
Subroutine _build_last_viewed_at: not called CC=1 SCAR=6.9
30 0 ▶sub _build_mention_count { shift->raw_data->{mention_count} }
Subroutine _build_mention_count: not called CC=1 SCAR=6.9
31 0 ▶sub _build_msg_count { shift->raw_data->{msg_count} }
Subroutine _build_msg_count: not called CC=1 SCAR=6.9
32  
33 sub _build_last_update {
34 0 ▶ my $self = shift;
Subroutine _build_last_update: not called CC=1 SCAR=6.9
35  
36 0 return $self->_from_epoch($self->last_update);
37 }
38  
39 sub _build_last_viewed {
40 0 ▶ my $self = shift;
Subroutine _build_last_viewed: not called CC=1 SCAR=6.9
41  
42 0 return $self->_from_epoch($self->last_update);
43 }
44  
45 ################################################################################
46  
47 12 1;
48  
49 __END__
50  
51 =pod
52  
53 =encoding UTF-8
54  
55 =head1 NAME
56  
57 WebService::Mattermost::V4::API::Object::Channel::Member - A channel member item.
58  
59 =head1 VERSION
60  
61 version 0.28
62  
63 =head1 DESCRIPTION
64  
65 A member of a channel.
66  
67 =head2 ATTRIBUTES
68  
69 =over 4
70  
71 =item C<notify_props>
72  
73 =item C<last_update_at>
74  
75 UNIX timestamp.
76  
77 =item C<last_viewed_at>
78  
79 UNIX timestamp.
80  
81 =item C<mention_count>
82  
83 =item C<msg_count>
84  
85 =item C<last_update>
86  
87 DateTime.
88  
89 =item C<last_viewed>
90  
91 DateTime.
92  
93 =back
94  
95 =head1 SEE ALSO
96  
97 =over 4
98  
99 =item L<WebService::Mattermost::V4::API::Object::Role::BelongingToUser>
100  
101 =item L<WebService::Mattermost::V4::API::Object::Role::BelongingToChannel>
102  
103 =item L<WebService::Mattermost::V4::API::Object::Role::Roles>
104  
105 =back
106  
107 =head1 AUTHOR
108  
109 Mike Jones <mike@netsplit.org.uk>
110  
111 =head1 COPYRIGHT AND LICENSE
112  
113 This software is Copyright (c) 2020 by Mike Jones.
114  
115 This is free software, licensed under:
116  
117 The MIT (X11) License
118  
119 =cut
« Mattermost/V4/API/Object/Job.pm ↑ Summary Mattermost/V4/API/Resource/Webhook/Incoming.pm »