Cfn/Resource/AWS/ApplicationAutoScaling/ScalingPolicy.pm

filter: Statementstmt 83.2% 124 / 149 Branchbran 15.0% 3 / 20 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 69.7% 23 / 33 Podpod 0.0% 0 / 2 totaltotal 73.5% 150 / 204 CC 11 SCAR 10.4
CC
11
Cov
75%
__ANON__
6.0
__ANON__
6.0
__ANON__
6.0
CRAP 2.8
« Cfn/Resource/AWS/Neptune/DBCluster.pm ↑ Summary Cfn/Resource/AWS/ElastiCache/ReplicationGroup.pm »
1 # AWS::ApplicationAutoScaling::ScalingPolicy generated from spec 18.4.0
2 2 ▶use Moose::Util::TypeConstraints;
Subroutine BEGIN: called CC=1 SCAR=0.0
3  
4 coerce 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy',
5 from 'HashRef',
6 2 ▶ via { Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy->new( %$_ ) };
Subroutine __ANON__: called CC=1 SCAR=0.0
7  
8 2 package Cfn::Resource::AWS::ApplicationAutoScaling::ScalingPolicy {
9 2 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
10 2 extends 'Cfn::Resource';
11 2 has Properties => (isa => 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy', is => 'rw', coerce => 1);
12
13 sub AttributeList {
14 1 ▶ [ ]
Subroutine AttributeList: called CC=1 SCAR=0.0
Pod undocumented
15 }
16 sub supported_regions {
17 1 ▶ [ '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' ]
Subroutine supported_regions: called CC=1 SCAR=0.0
Pod undocumented
18 }
19 }
20  
21  
22 subtype 'ArrayOfCfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::MetricDimension',
23 as 'Cfn::Value',
24 0 ▶ where { $_->isa('Cfn::Value::Array') or $_->isa('Cfn::Value::Function') },
Subroutine __ANON__: not called CC=2 SCAR=17.9
Branch: 1 branch
BranchTrueFalseTotal
$_->isa("Cfn::Value::Array") or $_->isa("Cfn::Value::Function") 0 0 0
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::ApplicationAutoScaling::ScalingPolicy::MetricDimension',
28 from 'HashRef',
29 via {
30 0 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Subroutine __ANON__: not called CC=2 SCAR=17.9
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 via {
38 Cfn::Value::Array->new(Value => [
39 map {
40 0 ▶ Moose::Util::TypeConstraints::find_type_constraint('Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::MetricDimension')->coerce($_)
Subroutine __ANON__: not called CC=1 SCAR=6.9
41 } @$_
42 ]);
43 2 };
44  
45 2 subtype 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::MetricDimension',
46 as 'Cfn::Value';
47  
48 coerce 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::MetricDimension',
49 from 'HashRef',
50 via {
51 0 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Subroutine __ANON__: not called CC=2 SCAR=17.9
Branch: 1 branch
BranchTrueFalseTotal
if (my $f = Cfn::TypeLibrary::try_function($_)) { } 0 0 0
52 0 return $f
53 } else {
54 0 return Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::MetricDimension->new( %$_ );
55 }
56 2 };
57  
58 2 package Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::MetricDimension {
59 2 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
60 2 ▶ use MooseX::StrictConstructor;
Subroutine BEGIN: called CC=1 SCAR=0.0
61 2 extends 'Cfn::Value::TypedValue';
62
63 2 has Name => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
64 2 has Value => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
65 }
66 subtype 'ArrayOfCfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::StepAdjustment',
67 as 'Cfn::Value',
68 2 ▶ 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") 0 2 2
69 0 ▶message { "$_ is not a Cfn::Value or a Cfn::Value::Function" };
Subroutine __ANON__: not called CC=1 SCAR=1.2
70  
71 coerce 'ArrayOfCfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::StepAdjustment',
72 from 'HashRef',
73 via {
74 0 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Subroutine __ANON__: not called CC=2 SCAR=17.9
Branch: 1 branch
BranchTrueFalseTotal
if (my $f = Cfn::TypeLibrary::try_function($_)) { } 0 0 0
75 0 return $f
76 } else {
77 0 die 'Only accepts functions';
78 }
79 },
80 from 'ArrayRef',
81 via {
82 Cfn::Value::Array->new(Value => [
83 map {
84 2 ▶ Moose::Util::TypeConstraints::find_type_constraint('Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::StepAdjustment')->coerce($_)
Subroutine __ANON__: called CC=1 SCAR=0.0
85 } @$_
86 ]);
87 2 };
88  
89 2 subtype 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::StepAdjustment',
90 as 'Cfn::Value';
91  
92 coerce 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::StepAdjustment',
93 from 'HashRef',
94 via {
95 2 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Subroutine __ANON__: called CC=2 SCAR=8.1
Branch: 1 branch
BranchTrueFalseTotal
if (my $f = Cfn::TypeLibrary::try_function($_)) { } 0 2 2
96 0 return $f
97 } else {
98 2 return Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::StepAdjustment->new( %$_ );
99 }
100 2 };
101  
102 2 package Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::StepAdjustment {
103 2 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
104 2 ▶ use MooseX::StrictConstructor;
Subroutine BEGIN: called CC=1 SCAR=0.0
105 2 extends 'Cfn::Value::TypedValue';
106
107 2 has MetricIntervalLowerBound => (isa => 'Cfn::Value::Double', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
108 2 has MetricIntervalUpperBound => (isa => 'Cfn::Value::Double', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
109 2 has ScalingAdjustment => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
110 }
111  
112 2 subtype 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::PredefinedMetricSpecification',
113 as 'Cfn::Value';
114  
115 coerce 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::PredefinedMetricSpecification',
116 from 'HashRef',
117 via {
118 0 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Subroutine __ANON__: not called CC=2 SCAR=17.9
Branch: 1 branch
BranchTrueFalseTotal
if (my $f = Cfn::TypeLibrary::try_function($_)) { } 0 0 0
119 0 return $f
120 } else {
121 0 return Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::PredefinedMetricSpecification->new( %$_ );
122 }
123 2 };
124  
125 2 package Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::PredefinedMetricSpecification {
126 2 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
127 2 ▶ use MooseX::StrictConstructor;
Subroutine BEGIN: called CC=1 SCAR=0.0
128 2 extends 'Cfn::Value::TypedValue';
129
130 2 has PredefinedMetricType => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
131 2 has ResourceLabel => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
132 }
133  
134 2 subtype 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::CustomizedMetricSpecification',
135 as 'Cfn::Value';
136  
137 coerce 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::CustomizedMetricSpecification',
138 from 'HashRef',
139 via {
140 0 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Subroutine __ANON__: not called CC=2 SCAR=17.9
Branch: 1 branch
BranchTrueFalseTotal
if (my $f = Cfn::TypeLibrary::try_function($_)) { } 0 0 0
141 0 return $f
142 } else {
143 0 return Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::CustomizedMetricSpecification->new( %$_ );
144 }
145 2 };
146  
147 2 package Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::CustomizedMetricSpecification {
148 2 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
149 2 ▶ use MooseX::StrictConstructor;
Subroutine BEGIN: called CC=1 SCAR=0.0
150 2 extends 'Cfn::Value::TypedValue';
151
152 2 has Dimensions => (isa => 'ArrayOfCfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::MetricDimension', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
153 2 has MetricName => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
154 2 has Namespace => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
155 2 has Statistic => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
156 2 has Unit => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
157 }
158  
159 2 subtype 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::TargetTrackingScalingPolicyConfiguration',
160 as 'Cfn::Value';
161  
162 coerce 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::TargetTrackingScalingPolicyConfiguration',
163 from 'HashRef',
164 via {
165 0 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Subroutine __ANON__: not called CC=2 SCAR=17.9
Branch: 1 branch
BranchTrueFalseTotal
if (my $f = Cfn::TypeLibrary::try_function($_)) { } 0 0 0
166 0 return $f
167 } else {
168 0 return Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::TargetTrackingScalingPolicyConfiguration->new( %$_ );
169 }
170 2 };
171  
172 2 package Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::TargetTrackingScalingPolicyConfiguration {
173 2 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
174 2 ▶ use MooseX::StrictConstructor;
Subroutine BEGIN: called CC=1 SCAR=0.0
175 2 extends 'Cfn::Value::TypedValue';
176
177 2 has CustomizedMetricSpecification => (isa => 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::CustomizedMetricSpecification', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
178 2 has DisableScaleIn => (isa => 'Cfn::Value::Boolean', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
179 2 has PredefinedMetricSpecification => (isa => 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::PredefinedMetricSpecification', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
180 2 has ScaleInCooldown => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
181 2 has ScaleOutCooldown => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
182 2 has TargetValue => (isa => 'Cfn::Value::Double', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
183 }
184  
185 2 subtype 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::StepScalingPolicyConfiguration',
186 as 'Cfn::Value';
187  
188 coerce 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::StepScalingPolicyConfiguration',
189 from 'HashRef',
190 via {
191 2 ▶ if (my $f = Cfn::TypeLibrary::try_function($_)) {
Subroutine __ANON__: called CC=2 SCAR=8.1
Branch: 1 branch
BranchTrueFalseTotal
if (my $f = Cfn::TypeLibrary::try_function($_)) { } 0 2 2
192 0 return $f
193 } else {
194 2 return Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::StepScalingPolicyConfiguration->new( %$_ );
195 }
196 2 };
197  
198 2 package Cfn::Resource::Properties::Object::AWS::ApplicationAutoScaling::ScalingPolicy::StepScalingPolicyConfiguration {
199 2 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
200 2 ▶ use MooseX::StrictConstructor;
Subroutine BEGIN: called CC=1 SCAR=0.0
201 2 extends 'Cfn::Value::TypedValue';
202
203 2 has AdjustmentType => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
204 2 has Cooldown => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
205 2 has MetricAggregationType => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
206 2 has MinAdjustmentMagnitude => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
207 2 has StepAdjustments => (isa => 'ArrayOfCfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::StepAdjustment', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
208 }
209  
210 2 package Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy {
211 2 ▶ use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
212 2 ▶ use MooseX::StrictConstructor;
Subroutine BEGIN: called CC=1 SCAR=0.0
213 2 extends 'Cfn::Resource::Properties';
214
215 2 has PolicyName => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Immutable');
216 2 has PolicyType => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
217 2 has ResourceId => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Immutable');
218 2 has ScalableDimension => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Immutable');
219 2 has ScalingTargetId => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Immutable');
220 2 has ServiceNamespace => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Immutable');
221 2 has StepScalingPolicyConfiguration => (isa => 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::StepScalingPolicyConfiguration', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
222 2 has TargetTrackingScalingPolicyConfiguration => (isa => 'Cfn::Resource::Properties::AWS::ApplicationAutoScaling::ScalingPolicy::TargetTrackingScalingPolicyConfiguration', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
223 }
224  
225 2 1;
226 ### main pod documentation begin ###
227  
228 =encoding UTF-8
229  
230 =head1 NAME
231  
232 Cfn::Resource::AWS::ApplicationAutoScaling::ScalingPolicy - Cfn resource for AWS::ApplicationAutoScaling::ScalingPolicy
233  
234 =head1 DESCRIPTION
235  
236 This module implements a Perl module that represents the CloudFormation object AWS::ApplicationAutoScaling::ScalingPolicy.
237  
238 See L<Cfn> for more information on how to use it.
239  
240 =head1 AUTHOR
241  
242 Jose Luis Martinez
243 CAPSiDE
244 jlmartinez@capside.com
245  
246 =head1 COPYRIGHT and LICENSE
247  
248 Copyright (c) 2013 by CAPSiDE
249 This code is distributed under the Apache 2 License. The full text of the
250 license can be found in the LICENSE file included with this module.
251  
252 =cut
« Cfn/Resource/AWS/Neptune/DBCluster.pm ↑ Summary Cfn/Resource/AWS/ElastiCache/ReplicationGroup.pm »