line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Elive::Entity::InvitedGuest; |
2
|
5
|
|
|
5
|
|
21
|
use warnings; use strict; |
|
5
|
|
|
5
|
|
7
|
|
|
5
|
|
|
|
|
141
|
|
|
5
|
|
|
|
|
18
|
|
|
5
|
|
|
|
|
6
|
|
|
5
|
|
|
|
|
119
|
|
3
|
|
|
|
|
|
|
|
4
|
5
|
|
|
5
|
|
17
|
use Mouse; |
|
5
|
|
|
|
|
8
|
|
|
5
|
|
|
|
|
23
|
|
5
|
5
|
|
|
5
|
|
1392
|
use Mouse::Util::TypeConstraints; |
|
5
|
|
|
|
|
7
|
|
|
5
|
|
|
|
|
24
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
extends 'Elive::Entity'; |
8
|
|
|
|
|
|
|
|
9
|
5
|
|
|
5
|
|
382
|
use Carp; |
|
5
|
|
|
|
|
9
|
|
|
5
|
|
|
|
|
1996
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
__PACKAGE__->entity_name('InvitedGuest'); |
12
|
|
|
|
|
|
|
__PACKAGE__->collection_name('InvitedGuests'); |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
has 'invitedGuestId' => (is => 'rw', isa => 'Int'); |
15
|
|
|
|
|
|
|
__PACKAGE__->_alias(id => 'invitedGuestId'); |
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
has 'loginName' => (is => 'rw', isa => 'Str', |
18
|
|
|
|
|
|
|
documentation => "Guest's login name (usually an email address)"); |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
has 'displayName' => (is => 'rw', isa => 'Str', |
21
|
|
|
|
|
|
|
documentation => "Guest's display name"); |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
sub BUILDARGS { |
24
|
0
|
|
|
0
|
1
|
|
my $class = shift; |
25
|
0
|
|
|
|
|
|
my $spec = shift; |
26
|
|
|
|
|
|
|
|
27
|
0
|
|
|
|
|
|
my $args; |
28
|
|
|
|
|
|
|
|
29
|
0
|
0
|
0
|
|
|
|
if ($spec && ! ref $spec) { |
30
|
0
|
0
|
|
|
|
|
if ($spec =~ m{^ \s* |
31
|
|
|
|
|
|
|
([^;]*?) # display name |
32
|
|
|
|
|
|
|
\s* |
33
|
|
|
|
|
|
|
\( ([^;\)]+) \) # (login name) |
34
|
|
|
|
|
|
|
\s* |
35
|
|
|
|
|
|
|
(= (\d) \s*)? # possible '=role' (ignored) |
36
|
|
|
|
|
|
|
$}x) { |
37
|
|
|
|
|
|
|
|
38
|
0
|
|
|
|
|
|
$args = {displayName => $1, loginName => $2}; |
39
|
|
|
|
|
|
|
} |
40
|
|
|
|
|
|
|
else { |
41
|
0
|
|
|
|
|
|
die "invited guest '$spec': not in format: ()'"; |
42
|
|
|
|
|
|
|
} |
43
|
|
|
|
|
|
|
} |
44
|
|
|
|
|
|
|
else { |
45
|
0
|
|
|
|
|
|
$args = $spec; |
46
|
|
|
|
|
|
|
} |
47
|
|
|
|
|
|
|
|
48
|
0
|
|
|
|
|
|
return $args; |
49
|
|
|
|
|
|
|
} |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
coerce 'Elive::Entity::InvitedGuest' => from 'HashRef|Str' |
52
|
|
|
|
|
|
|
=> via {Elive::Entity::InvitedGuest->new($_)}; |
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
=head1 NAME |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
Elive::Entity::InvitedGuest - Invited Guest entity class |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
=head1 DESCRIPTION |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
This is the structural class for an invited guest. It is associated with |
61
|
|
|
|
|
|
|
meetings via the L entity. |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
=cut |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=head1 METHODS |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
=cut |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
=head2 stringify |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
Serialize a guest as (): e.g. C. |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
=cut |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
sub stringify { |
76
|
0
|
|
|
0
|
1
|
|
my $self = shift; |
77
|
0
|
|
0
|
|
|
|
my $data = shift || $self; |
78
|
|
|
|
|
|
|
|
79
|
0
|
0
|
|
|
|
|
return $data |
80
|
|
|
|
|
|
|
unless Scalar::Util::refaddr($data); |
81
|
|
|
|
|
|
|
|
82
|
0
|
|
|
|
|
|
return sprintf("%s (%s)", $data->{displayName}, $data->{loginName}); |
83
|
|
|
|
|
|
|
} |
84
|
|
|
|
|
|
|
|
85
|
|
|
|
|
|
|
sub _retrieve_all { |
86
|
0
|
|
|
0
|
|
|
my ($class, $vals, %opt) = @_; |
87
|
|
|
|
|
|
|
|
88
|
|
|
|
|
|
|
# |
89
|
|
|
|
|
|
|
# No getXxxx command use listXxxx |
90
|
|
|
|
|
|
|
# |
91
|
0
|
|
|
|
|
|
return $class->SUPER::_retrieve_all($vals, |
92
|
|
|
|
|
|
|
command => 'listInvitedGuests', |
93
|
|
|
|
|
|
|
%opt); |
94
|
|
|
|
|
|
|
} |
95
|
|
|
|
|
|
|
|
96
|
|
|
|
|
|
|
=head1 SEE ALSO |
97
|
|
|
|
|
|
|
|
98
|
|
|
|
|
|
|
=over 4 |
99
|
|
|
|
|
|
|
|
100
|
|
|
|
|
|
|
=item Elive::Entity::Session |
101
|
|
|
|
|
|
|
=item Elive::Entity::Meeting |
102
|
|
|
|
|
|
|
|
103
|
|
|
|
|
|
|
=back |
104
|
|
|
|
|
|
|
|
105
|
|
|
|
|
|
|
=cut |
106
|
|
|
|
|
|
|
|
107
|
|
|
|
|
|
|
1; |