line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package JMAP::Validation::Generators::ContactGroup; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
920
|
use strict; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
49
|
|
4
|
2
|
|
|
2
|
|
7
|
use warnings; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
40
|
|
5
|
|
|
|
|
|
|
|
6
|
2
|
|
|
2
|
|
587
|
use JMAP::Validation::Generators::String; |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
49
|
|
7
|
2
|
|
|
2
|
|
7
|
use JSON::Typist; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
181
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub generate { |
10
|
2
|
|
|
2
|
0
|
144
|
my (%args) = @_; |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
my @contactIds |
13
|
2
|
|
|
|
|
6
|
= map { JMAP::Validation::Generators::String->generate() } |
|
4
|
|
|
|
|
1418
|
|
14
|
|
|
|
|
|
|
1..2; |
15
|
|
|
|
|
|
|
|
16
|
2
|
|
|
|
|
68
|
my @ContactGroups; |
17
|
|
|
|
|
|
|
|
18
|
2
|
|
|
|
|
7
|
foreach my $contactIds ([@contactIds], []) { |
19
|
|
|
|
|
|
|
push @ContactGroups, { |
20
|
4
|
50
|
|
|
|
85
|
($args{no_id} ? () : (id => JMAP::Validation::Generators::String->generate())), |
21
|
|
|
|
|
|
|
name => JMAP::Validation::Generators::String->generate(), |
22
|
|
|
|
|
|
|
contactIds => $contactIds, |
23
|
|
|
|
|
|
|
}; |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
2
|
|
|
|
|
68
|
return @ContactGroups; |
27
|
|
|
|
|
|
|
} |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
1; |