Cfn/Resource/AWS/EC2/SecurityGroup.pm

filter: Statementstmt 86.6% 78 / 90 Branchbran 33.3% 4 / 12 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 71.4% 15 / 21 Podpod 0.0% 0 / 2 totaltotal 77.6% 97 / 125 CC 7 SCAR 7.8
CC
7
Cov
80%
__ANON__
6.0
__ANON__
6.0
__ANON__
2.3
CRAP 2.2
« Cfn/Resource/AWS/ElasticLoadBalancingV2/LoadBalancer.pm ↑ Summary Cfn/Resource/AWS/Route53/RecordSetGroup.pm »
1 # AWS::EC2::SecurityGroup generated from spec 18.4.0
2 4 ▶use Moose::Util::TypeConstraints;
Subroutine BEGIN: called CC=1 SCAR=0.0
3  
4 coerce 'Cfn::Resource::Properties::AWS::EC2::SecurityGroup',
5 from 'HashRef',
6 129 ▶ via { Cfn::Resource::Properties::AWS::EC2::SecurityGroup->new( %$_ ) };
Subroutine __ANON__: called CC=1 SCAR=0.0
7  
8 4 package Cfn::Resource::AWS::EC2::SecurityGroup {
9 4 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
10 4 extends 'Cfn::Resource';
11 4 has Properties => (isa => 'Cfn::Resource::Properties::AWS::EC2::SecurityGroup', is => 'rw', coerce => 1);
12
13 0 ▶ sub AttributeList {
Subroutine AttributeList: not called CC=1 SCAR=6.9
Pod undocumented
14 0 [ 'GroupId','VpcId' ]
15 }
16 0 ▶ sub supported_regions {
Subroutine supported_regions: not called CC=1 SCAR=6.9
Pod undocumented
17 0 [ 'af-south-1','ap-east-1','ap-northeast-1','ap-northeast-2','ap-northeast-3','ap-south-1','ap-southeast-1','ap-southeast-2','ca-central-1','cn-north-1','cn-northwest-1','eu-central-1','eu-north-1','eu-south-1','eu-west-1','eu-west-2','eu-west-3','me-south-1','sa-east-1','us-east-1','us-east-2','us-gov-east-1','us-gov-west-1','us-west-1','us-west-2' ]
18 }
19 }
20  
21  
22 subtype 'ArrayOfCfn::Resource::Properties::AWS::EC2::SecurityGroup::Ingress',
23 as 'Cfn::Value',
24 116 ▶ where { $_->isa('Cfn::Value::Array') or $_->isa('Cfn::Value::Function') },
Subroutine __ANON__: called CC=2 SCAR=7.6
Branch: 1 branch
BranchTrueFalseTotal
$_->isa("Cfn::Value::Array") or $_->isa("Cfn::Value::Function") 116 0 116
25 0 ▶message { "$_ is not a Cfn::Value or a Cfn::Value::Function" };
Subroutine __ANON__: not called CC=1 SCAR=1.2
26  
27 coerce 'ArrayOfCfn::Resource::Properties::AWS::EC2::SecurityGroup::Ingress',
28 from 'HashRef',
29 0 ▶ via {
Subroutine __ANON__: not called CC=2 SCAR=17.9
30 0 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Branch: 1 branch
BranchTrueFalseTotal
if (my $f = Cfn::TypeLibrary::try_function($_)) { } 0 0 0
31 0 return $f
32 } else {
33 0 die 'Only accepts functions';
34 }
35 },
36 from 'ArrayRef',
37 116 ▶ via {
Subroutine __ANON__: called CC=1 SCAR=0.0
38 Cfn::Value::Array->new(Value => [
39 map {
40 116 Moose::Util::TypeConstraints::find_type_constraint('Cfn::Resource::Properties::AWS::EC2::SecurityGroup::Ingress')->coerce($_)
41 } @$_
42 ]);
43 4 };
44  
45 4 subtype 'Cfn::Resource::Properties::AWS::EC2::SecurityGroup::Ingress',
46 as 'Cfn::Value';
47  
48 coerce 'Cfn::Resource::Properties::AWS::EC2::SecurityGroup::Ingress',
49 from 'HashRef',
50 222 ▶ via {
Subroutine __ANON__: called CC=2 SCAR=8.1
51 222 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Branch: 1 branch
BranchTrueFalseTotal
if (my $f = Cfn::TypeLibrary::try_function($_)) { } 0 222 222
52 0 return $f
53 } else {
54 222 return Cfn::Resource::Properties::Object::AWS::EC2::SecurityGroup::Ingress->new( %$_ );
55 }
56 4 };
57  
58 4 package Cfn::Resource::Properties::Object::AWS::EC2::SecurityGroup::Ingress {
59 4 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
60 4 ▶ use MooseX::StrictConstructor;
Subroutine BEGIN: called CC=1 SCAR=0.0
61 4 extends 'Cfn::Value::TypedValue';
62
63 4 has CidrIp => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
64 4 has CidrIpv6 => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
65 4 has Description => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
66 4 has FromPort => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
67 4 has IpProtocol => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
68 4 has SourcePrefixListId => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
69 4 has SourceSecurityGroupId => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
70 4 has SourceSecurityGroupName => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
71 4 has SourceSecurityGroupOwnerId => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
72 4 has ToPort => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
73 }
74 subtype 'ArrayOfCfn::Resource::Properties::AWS::EC2::SecurityGroup::Egress',
75 as 'Cfn::Value',
76 16 ▶ where { $_->isa('Cfn::Value::Array') or $_->isa('Cfn::Value::Function') },
Subroutine __ANON__: called CC=2 SCAR=7.6
Branch: 1 branch
BranchTrueFalseTotal
$_->isa("Cfn::Value::Array") or $_->isa("Cfn::Value::Function") 16 0 16
77 0 ▶message { "$_ is not a Cfn::Value or a Cfn::Value::Function" };
Subroutine __ANON__: not called CC=1 SCAR=1.2
78  
79 coerce 'ArrayOfCfn::Resource::Properties::AWS::EC2::SecurityGroup::Egress',
80 from 'HashRef',
81 0 ▶ via {
Subroutine __ANON__: not called CC=2 SCAR=17.9
82 0 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Branch: 1 branch
BranchTrueFalseTotal
if (my $f = Cfn::TypeLibrary::try_function($_)) { } 0 0 0
83 0 return $f
84 } else {
85 0 die 'Only accepts functions';
86 }
87 },
88 from 'ArrayRef',
89 16 ▶ via {
Subroutine __ANON__: called CC=1 SCAR=0.0
90 Cfn::Value::Array->new(Value => [
91 map {
92 16 Moose::Util::TypeConstraints::find_type_constraint('Cfn::Resource::Properties::AWS::EC2::SecurityGroup::Egress')->coerce($_)
93 } @$_
94 ]);
95 4 };
96  
97 4 subtype 'Cfn::Resource::Properties::AWS::EC2::SecurityGroup::Egress',
98 as 'Cfn::Value';
99  
100 coerce 'Cfn::Resource::Properties::AWS::EC2::SecurityGroup::Egress',
101 from 'HashRef',
102 22 ▶ via {
Subroutine __ANON__: called CC=2 SCAR=8.1
103 22 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Branch: 1 branch
BranchTrueFalseTotal
if (my $f = Cfn::TypeLibrary::try_function($_)) { } 0 22 22
104 0 return $f
105 } else {
106 22 return Cfn::Resource::Properties::Object::AWS::EC2::SecurityGroup::Egress->new( %$_ );
107 }
108 4 };
109  
110 4 package Cfn::Resource::Properties::Object::AWS::EC2::SecurityGroup::Egress {
111 4 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
112 4 ▶ use MooseX::StrictConstructor;
Subroutine BEGIN: called CC=1 SCAR=0.0
113 4 extends 'Cfn::Value::TypedValue';
114
115 4 has CidrIp => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
116 4 has CidrIpv6 => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
117 4 has Description => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
118 4 has DestinationPrefixListId => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
119 4 has DestinationSecurityGroupId => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
120 4 has FromPort => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
121 4 has IpProtocol => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
122 4 has ToPort => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
123 }
124  
125 4 package Cfn::Resource::Properties::AWS::EC2::SecurityGroup {
126 4 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
127 4 ▶ use MooseX::StrictConstructor;
Subroutine BEGIN: called CC=1 SCAR=0.0
128 4 extends 'Cfn::Resource::Properties';
129
130 4 has GroupDescription => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Immutable');
131 4 has GroupName => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Immutable');
132 4 has SecurityGroupEgress => (isa => 'ArrayOfCfn::Resource::Properties::AWS::EC2::SecurityGroup::Egress', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
133 4 has SecurityGroupIngress => (isa => 'ArrayOfCfn::Resource::Properties::AWS::EC2::SecurityGroup::Ingress', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
134 4 has Tags => (isa => 'ArrayOfCfn::Resource::Properties::TagType', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
135 4 has VpcId => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Immutable');
136 }
137  
138 4 1;
139 ### main pod documentation begin ###
140  
141 =encoding UTF-8
142  
143 =head1 NAME
144  
145 Cfn::Resource::AWS::EC2::SecurityGroup - Cfn resource for AWS::EC2::SecurityGroup
146  
147 =head1 DESCRIPTION
148  
149 This module implements a Perl module that represents the CloudFormation object AWS::EC2::SecurityGroup.
150  
151 See L<Cfn> for more information on how to use it.
152  
153 =head1 AUTHOR
154  
155 Jose Luis Martinez
156 CAPSiDE
157 jlmartinez@capside.com
158  
159 =head1 COPYRIGHT and LICENSE
160  
161 Copyright (c) 2013 by CAPSiDE
162 This code is distributed under the Apache 2 License. The full text of the
163 license can be found in the LICENSE file included with this module.
164  
165 =cut
« Cfn/Resource/AWS/ElasticLoadBalancingV2/LoadBalancer.pm ↑ Summary Cfn/Resource/AWS/Route53/RecordSetGroup.pm »