File Coverage

blib/lib/Cfn/Resource/AWS/Lambda/Function.pm
Criterion Covered Total %
statement 44 44 100.0
branch n/a
condition n/a
subroutine 16 16 100.0
pod 0 2 0.0
total 60 62 96.7


line stmt bran cond sub pod time code
1             # AWS::Lambda::Function generated from spec 5.3.0
2 4     4   2762 use Moose::Util::TypeConstraints;
  4         12  
  4         41  
3              
4             coerce 'Cfn::Resource::Properties::AWS::Lambda::Function',
5             from 'HashRef',
6             via { Cfn::Resource::Properties::AWS::Lambda::Function->new( %$_ ) };
7              
8             package Cfn::Resource::AWS::Lambda::Function {
9 4     4   8419 use Moose;
  4         10  
  4         27  
10             extends 'Cfn::Resource';
11             has Properties => (isa => 'Cfn::Resource::Properties::AWS::Lambda::Function', is => 'rw', coerce => 1);
12            
13             sub AttributeList {
14 1     1 0 4 [ 'Arn' ]
15             }
16             sub supported_regions {
17 6     6 0 1158 [ '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-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              
23             subtype 'Cfn::Resource::Properties::AWS::Lambda::Function::VpcConfig',
24             as 'Cfn::Value';
25              
26             coerce 'Cfn::Resource::Properties::AWS::Lambda::Function::VpcConfig',
27             from 'HashRef',
28             via {
29             if (my $f = Cfn::TypeLibrary::try_function($_)) {
30             return $f
31             } else {
32             return Cfn::Resource::Properties::AWS::Lambda::Function::VpcConfigValue->new( %$_ );
33             }
34             };
35              
36             package Cfn::Resource::Properties::AWS::Lambda::Function::VpcConfigValue {
37 4     4   28217 use Moose;
  4         11  
  4         29  
38 4     4   25209 use MooseX::StrictConstructor;
  4         11  
  4         41  
39             extends 'Cfn::Value::TypedValue';
40            
41             has SecurityGroupIds => (isa => 'Cfn::Value::Array|Cfn::Value::Function|Cfn::DynamicValue', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
42             has SubnetIds => (isa => 'Cfn::Value::Array|Cfn::Value::Function|Cfn::DynamicValue', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
43             }
44              
45             subtype 'Cfn::Resource::Properties::AWS::Lambda::Function::TracingConfig',
46             as 'Cfn::Value';
47              
48             coerce 'Cfn::Resource::Properties::AWS::Lambda::Function::TracingConfig',
49             from 'HashRef',
50             via {
51             if (my $f = Cfn::TypeLibrary::try_function($_)) {
52             return $f
53             } else {
54             return Cfn::Resource::Properties::AWS::Lambda::Function::TracingConfigValue->new( %$_ );
55             }
56             };
57              
58             package Cfn::Resource::Properties::AWS::Lambda::Function::TracingConfigValue {
59 4     4   13600 use Moose;
  4         10  
  4         21  
60 4     4   25277 use MooseX::StrictConstructor;
  4         11  
  4         25  
61             extends 'Cfn::Value::TypedValue';
62            
63             has Mode => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
64             }
65              
66             subtype 'Cfn::Resource::Properties::AWS::Lambda::Function::Environment',
67             as 'Cfn::Value';
68              
69             coerce 'Cfn::Resource::Properties::AWS::Lambda::Function::Environment',
70             from 'HashRef',
71             via {
72             if (my $f = Cfn::TypeLibrary::try_function($_)) {
73             return $f
74             } else {
75             return Cfn::Resource::Properties::AWS::Lambda::Function::EnvironmentValue->new( %$_ );
76             }
77             };
78              
79             package Cfn::Resource::Properties::AWS::Lambda::Function::EnvironmentValue {
80 4     4   12859 use Moose;
  4         13  
  4         22  
81 4     4   25313 use MooseX::StrictConstructor;
  4         13  
  4         23  
82             extends 'Cfn::Value::TypedValue';
83            
84             has Variables => (isa => 'Cfn::Value::Hash|Cfn::DynamicValue', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
85             }
86              
87             subtype 'Cfn::Resource::Properties::AWS::Lambda::Function::DeadLetterConfig',
88             as 'Cfn::Value';
89              
90             coerce 'Cfn::Resource::Properties::AWS::Lambda::Function::DeadLetterConfig',
91             from 'HashRef',
92             via {
93             if (my $f = Cfn::TypeLibrary::try_function($_)) {
94             return $f
95             } else {
96             return Cfn::Resource::Properties::AWS::Lambda::Function::DeadLetterConfigValue->new( %$_ );
97             }
98             };
99              
100             package Cfn::Resource::Properties::AWS::Lambda::Function::DeadLetterConfigValue {
101 4     4   12719 use Moose;
  4         14  
  4         21  
102 4     4   24971 use MooseX::StrictConstructor;
  4         10  
  4         23  
103             extends 'Cfn::Value::TypedValue';
104            
105             has TargetArn => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
106             }
107              
108             subtype 'Cfn::Resource::Properties::AWS::Lambda::Function::Code',
109             as 'Cfn::Value';
110              
111             coerce 'Cfn::Resource::Properties::AWS::Lambda::Function::Code',
112             from 'HashRef',
113             via {
114             if (my $f = Cfn::TypeLibrary::try_function($_)) {
115             return $f
116             } else {
117             return Cfn::Resource::Properties::AWS::Lambda::Function::CodeValue->new( %$_ );
118             }
119             };
120              
121             package Cfn::Resource::Properties::AWS::Lambda::Function::CodeValue {
122 4     4   12805 use Moose;
  4         14  
  4         20  
123 4     4   25503 use MooseX::StrictConstructor;
  4         14  
  4         21  
124             extends 'Cfn::Value::TypedValue';
125            
126             has S3Bucket => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
127             has S3Key => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
128             has S3ObjectVersion => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
129             has ZipFile => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
130             }
131              
132             package Cfn::Resource::Properties::AWS::Lambda::Function {
133 4     4   12622 use Moose;
  4         10  
  4         24  
134 4     4   24891 use MooseX::StrictConstructor;
  4         12  
  4         21  
135             extends 'Cfn::Resource::Properties';
136            
137             has Code => (isa => 'Cfn::Resource::Properties::AWS::Lambda::Function::Code', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
138             has DeadLetterConfig => (isa => 'Cfn::Resource::Properties::AWS::Lambda::Function::DeadLetterConfig', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
139             has Description => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
140             has Environment => (isa => 'Cfn::Resource::Properties::AWS::Lambda::Function::Environment', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
141             has FunctionName => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Immutable');
142             has Handler => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
143             has KmsKeyArn => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
144             has Layers => (isa => 'Cfn::Value::Array|Cfn::Value::Function|Cfn::DynamicValue', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
145             has MemorySize => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
146             has ReservedConcurrentExecutions => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
147             has Role => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
148             has Runtime => (isa => 'Cfn::Value::String', is => 'rw', coerce => 1, required => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
149             has Tags => (isa => 'ArrayOfCfn::Resource::Properties::TagType', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
150             has Timeout => (isa => 'Cfn::Value::Integer', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
151             has TracingConfig => (isa => 'Cfn::Resource::Properties::AWS::Lambda::Function::TracingConfig', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
152             has VpcConfig => (isa => 'Cfn::Resource::Properties::AWS::Lambda::Function::VpcConfig', is => 'rw', coerce => 1, traits => [ 'CfnMutability' ], mutability => 'Mutable');
153             }
154              
155             1;