|
| 1 | +function Add-VSACMPCACertificateAuthorityCrlConfiguration { |
| 2 | + <# |
| 3 | + .SYNOPSIS |
| 4 | + Adds an AWS::ACMPCA::CertificateAuthority.CrlConfiguration resource property to the template. |
| 5 | +
|
| 6 | + .DESCRIPTION |
| 7 | + Adds an AWS::ACMPCA::CertificateAuthority.CrlConfiguration resource property to the template. |
| 8 | +
|
| 9 | +
|
| 10 | + .LINK |
| 11 | + http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-acmpca-certificateauthority-crlconfiguration.html |
| 12 | +
|
| 13 | + .PARAMETER Enabled |
| 14 | + Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-acmpca-certificateauthority-crlconfiguration.html#cfn-acmpca-certificateauthority-crlconfiguration-enabled |
| 15 | + UpdateType: Mutable |
| 16 | + PrimitiveType: Boolean |
| 17 | +
|
| 18 | + .PARAMETER ExpirationInDays |
| 19 | + Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-acmpca-certificateauthority-crlconfiguration.html#cfn-acmpca-certificateauthority-crlconfiguration-expirationindays |
| 20 | + UpdateType: Mutable |
| 21 | + PrimitiveType: Integer |
| 22 | +
|
| 23 | + .PARAMETER CustomCname |
| 24 | + Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-acmpca-certificateauthority-crlconfiguration.html#cfn-acmpca-certificateauthority-crlconfiguration-customcname |
| 25 | + UpdateType: Mutable |
| 26 | + PrimitiveType: String |
| 27 | +
|
| 28 | + .PARAMETER S3BucketName |
| 29 | + Documentation: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-acmpca-certificateauthority-crlconfiguration.html#cfn-acmpca-certificateauthority-crlconfiguration-s3bucketname |
| 30 | + UpdateType: Mutable |
| 31 | + PrimitiveType: String |
| 32 | +
|
| 33 | + .FUNCTIONALITY |
| 34 | + Vaporshell |
| 35 | + #> |
| 36 | + [OutputType('Vaporshell.Resource.ACMPCA.CertificateAuthority.CrlConfiguration')] |
| 37 | + [cmdletbinding()] |
| 38 | + Param |
| 39 | + ( |
| 40 | + [parameter(Mandatory = $false)] |
| 41 | + [ValidateScript( { |
| 42 | + $allowedTypes = "System.Boolean","Vaporshell.Function" |
| 43 | + if ([string]$($_.PSTypeNames) -match "($(($allowedTypes|ForEach-Object{[RegEx]::Escape($_)}) -join '|'))") { |
| 44 | + $true |
| 45 | + } |
| 46 | + else { |
| 47 | + $PSCmdlet.ThrowTerminatingError((New-VSError -String "This parameter only accepts the following types: $($allowedTypes -join ", "). The current types of the value are: $($_.PSTypeNames -join ", ").")) |
| 48 | + } |
| 49 | + })] |
| 50 | + $Enabled, |
| 51 | + [parameter(Mandatory = $false)] |
| 52 | + [ValidateScript( { |
| 53 | + $allowedTypes = "System.Int32","Vaporshell.Function" |
| 54 | + if ([string]$($_.PSTypeNames) -match "($(($allowedTypes|ForEach-Object{[RegEx]::Escape($_)}) -join '|'))") { |
| 55 | + $true |
| 56 | + } |
| 57 | + else { |
| 58 | + $PSCmdlet.ThrowTerminatingError((New-VSError -String "This parameter only accepts the following types: $($allowedTypes -join ", "). The current types of the value are: $($_.PSTypeNames -join ", ").")) |
| 59 | + } |
| 60 | + })] |
| 61 | + $ExpirationInDays, |
| 62 | + [parameter(Mandatory = $false)] |
| 63 | + [ValidateScript( { |
| 64 | + $allowedTypes = "System.String","Vaporshell.Function","Vaporshell.Condition" |
| 65 | + if ([string]$($_.PSTypeNames) -match "($(($allowedTypes|ForEach-Object{[RegEx]::Escape($_)}) -join '|'))") { |
| 66 | + $true |
| 67 | + } |
| 68 | + else { |
| 69 | + $PSCmdlet.ThrowTerminatingError((New-VSError -String "This parameter only accepts the following types: $($allowedTypes -join ", "). The current types of the value are: $($_.PSTypeNames -join ", ").")) |
| 70 | + } |
| 71 | + })] |
| 72 | + $CustomCname, |
| 73 | + [parameter(Mandatory = $false)] |
| 74 | + [ValidateScript( { |
| 75 | + $allowedTypes = "System.String","Vaporshell.Function","Vaporshell.Condition" |
| 76 | + if ([string]$($_.PSTypeNames) -match "($(($allowedTypes|ForEach-Object{[RegEx]::Escape($_)}) -join '|'))") { |
| 77 | + $true |
| 78 | + } |
| 79 | + else { |
| 80 | + $PSCmdlet.ThrowTerminatingError((New-VSError -String "This parameter only accepts the following types: $($allowedTypes -join ", "). The current types of the value are: $($_.PSTypeNames -join ", ").")) |
| 81 | + } |
| 82 | + })] |
| 83 | + $S3BucketName |
| 84 | + ) |
| 85 | + Begin { |
| 86 | + $obj = [PSCustomObject]@{} |
| 87 | + $commonParams = @('Verbose','Debug','ErrorAction','WarningAction','InformationAction','ErrorVariable','WarningVariable','InformationVariable','OutVariable','OutBuffer','PipelineVariable') |
| 88 | + } |
| 89 | + Process { |
| 90 | + foreach ($key in $PSBoundParameters.Keys | Where-Object {$commonParams -notcontains $_}) { |
| 91 | + switch ($key) { |
| 92 | + Default { |
| 93 | + $obj | Add-Member -MemberType NoteProperty -Name $key -Value $PSBoundParameters.$key |
| 94 | + } |
| 95 | + } |
| 96 | + } |
| 97 | + } |
| 98 | + End { |
| 99 | + $obj | Add-ObjectDetail -TypeName 'Vaporshell.Resource.ACMPCA.CertificateAuthority.CrlConfiguration' |
| 100 | + Write-Verbose "Resulting JSON from $($MyInvocation.MyCommand): `n`n$($obj | ConvertTo-Json -Depth 5)`n" |
| 101 | + } |
| 102 | +} |
0 commit comments