@cdktf/provider-aws
Version:
Prebuilt aws Provider for Terraform CDK (cdktf)
980 lines • 172 kB
JavaScript
"use strict";
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
Object.defineProperty(exports, "__esModule", { value: true });
exports.Wafv2WebAclLoggingConfiguration = exports.Wafv2WebAclLoggingConfigurationRedactedFieldsList = exports.Wafv2WebAclLoggingConfigurationRedactedFieldsOutputReference = exports.wafv2WebAclLoggingConfigurationRedactedFieldsToHclTerraform = exports.wafv2WebAclLoggingConfigurationRedactedFieldsToTerraform = exports.Wafv2WebAclLoggingConfigurationRedactedFieldsUriPathOutputReference = exports.wafv2WebAclLoggingConfigurationRedactedFieldsUriPathToHclTerraform = exports.wafv2WebAclLoggingConfigurationRedactedFieldsUriPathToTerraform = exports.Wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderOutputReference = exports.wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderToHclTerraform = exports.wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderToTerraform = exports.Wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringOutputReference = exports.wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringToHclTerraform = exports.wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringToTerraform = exports.Wafv2WebAclLoggingConfigurationRedactedFieldsMethodOutputReference = exports.wafv2WebAclLoggingConfigurationRedactedFieldsMethodToHclTerraform = exports.wafv2WebAclLoggingConfigurationRedactedFieldsMethodToTerraform = exports.Wafv2WebAclLoggingConfigurationLoggingFilterOutputReference = exports.wafv2WebAclLoggingConfigurationLoggingFilterToHclTerraform = exports.wafv2WebAclLoggingConfigurationLoggingFilterToTerraform = exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterList = exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterOutputReference = exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterToHclTerraform = exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterToTerraform = exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionList = exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionOutputReference = exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionToHclTerraform = exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionToTerraform = exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionOutputReference = exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionToHclTerraform = exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionToTerraform = exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionOutputReference = exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionToHclTerraform = exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionToTerraform = void 0;
const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti");
const cdktf = require("cdktf");
function wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionToTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
return {
action: cdktf.stringToTerraform(struct.action),
};
}
exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionToTerraform = wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionToTerraform;
function wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionToHclTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
const attrs = {
action: {
value: cdktf.stringToHclTerraform(struct.action),
isBlock: false,
type: "simple",
storageClassType: "string",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionToHclTerraform = wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionToHclTerraform;
class Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionOutputReference extends cdktf.ComplexObject {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
*/
constructor(terraformResource, terraformAttribute) {
super(terraformResource, terraformAttribute, false, 0);
this.isEmptyObject = false;
}
get internalValue() {
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._action !== undefined) {
hasAnyValues = true;
internalValueResult.action = this._action;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._action = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._action = value.action;
}
}
get action() {
return this.getStringAttribute('action');
}
set action(value) {
this._action = value;
}
// Temporarily expose input value. Use with caution.
get actionInput() {
return this._action;
}
}
exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionOutputReference = Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionOutputReference;
_a = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionOutputReference[_a] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionOutputReference", version: "19.50.0" };
function wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionToTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
return {
label_name: cdktf.stringToTerraform(struct.labelName),
};
}
exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionToTerraform = wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionToTerraform;
function wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionToHclTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
const attrs = {
label_name: {
value: cdktf.stringToHclTerraform(struct.labelName),
isBlock: false,
type: "simple",
storageClassType: "string",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionToHclTerraform = wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionToHclTerraform;
class Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionOutputReference extends cdktf.ComplexObject {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
*/
constructor(terraformResource, terraformAttribute) {
super(terraformResource, terraformAttribute, false, 0);
this.isEmptyObject = false;
}
get internalValue() {
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._labelName !== undefined) {
hasAnyValues = true;
internalValueResult.labelName = this._labelName;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._labelName = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._labelName = value.labelName;
}
}
get labelName() {
return this.getStringAttribute('label_name');
}
set labelName(value) {
this._labelName = value;
}
// Temporarily expose input value. Use with caution.
get labelNameInput() {
return this._labelName;
}
}
exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionOutputReference = Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionOutputReference;
_b = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionOutputReference[_b] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionOutputReference", version: "19.50.0" };
function wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionToTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
return {
action_condition: wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionToTerraform(struct.actionCondition),
label_name_condition: wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionToTerraform(struct.labelNameCondition),
};
}
exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionToTerraform = wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionToTerraform;
function wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionToHclTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
const attrs = {
action_condition: {
value: wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionToHclTerraform(struct.actionCondition),
isBlock: true,
type: "list",
storageClassType: "Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionList",
},
label_name_condition: {
value: wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionToHclTerraform(struct.labelNameCondition),
isBlock: true,
type: "list",
storageClassType: "Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionList",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionToHclTerraform = wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionToHclTerraform;
class Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionOutputReference extends cdktf.ComplexObject {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
* @param complexObjectIndex the index of this item in the list
* @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
*/
constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) {
super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex);
this.isEmptyObject = false;
// action_condition - computed: false, optional: true, required: false
this._actionCondition = new Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionActionConditionOutputReference(this, "action_condition");
// label_name_condition - computed: false, optional: true, required: false
this._labelNameCondition = new Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionLabelNameConditionOutputReference(this, "label_name_condition");
}
get internalValue() {
if (this.resolvableValue) {
return this.resolvableValue;
}
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._actionCondition?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.actionCondition = this._actionCondition?.internalValue;
}
if (this._labelNameCondition?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.labelNameCondition = this._labelNameCondition?.internalValue;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this.resolvableValue = undefined;
this._actionCondition.internalValue = undefined;
this._labelNameCondition.internalValue = undefined;
}
else if (cdktf.Tokenization.isResolvable(value)) {
this.isEmptyObject = false;
this.resolvableValue = value;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this.resolvableValue = undefined;
this._actionCondition.internalValue = value.actionCondition;
this._labelNameCondition.internalValue = value.labelNameCondition;
}
}
get actionCondition() {
return this._actionCondition;
}
putActionCondition(value) {
this._actionCondition.internalValue = value;
}
resetActionCondition() {
this._actionCondition.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get actionConditionInput() {
return this._actionCondition.internalValue;
}
get labelNameCondition() {
return this._labelNameCondition;
}
putLabelNameCondition(value) {
this._labelNameCondition.internalValue = value;
}
resetLabelNameCondition() {
this._labelNameCondition.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get labelNameConditionInput() {
return this._labelNameCondition.internalValue;
}
}
exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionOutputReference = Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionOutputReference;
_c = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionOutputReference[_c] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionOutputReference", version: "19.50.0" };
class Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionList extends cdktf.ComplexList {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
* @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
*/
constructor(terraformResource, terraformAttribute, wrapsSet) {
super(terraformResource, terraformAttribute, wrapsSet);
this.terraformResource = terraformResource;
this.terraformAttribute = terraformAttribute;
this.wrapsSet = wrapsSet;
}
/**
* @param index the index of the item to return
*/
get(index) {
return new Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
}
}
exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionList = Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionList;
_d = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionList[_d] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionList", version: "19.50.0" };
function wafv2WebAclLoggingConfigurationLoggingFilterFilterToTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
return {
behavior: cdktf.stringToTerraform(struct.behavior),
requirement: cdktf.stringToTerraform(struct.requirement),
condition: cdktf.listMapper(wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionToTerraform, true)(struct.condition),
};
}
exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterToTerraform = wafv2WebAclLoggingConfigurationLoggingFilterFilterToTerraform;
function wafv2WebAclLoggingConfigurationLoggingFilterFilterToHclTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
const attrs = {
behavior: {
value: cdktf.stringToHclTerraform(struct.behavior),
isBlock: false,
type: "simple",
storageClassType: "string",
},
requirement: {
value: cdktf.stringToHclTerraform(struct.requirement),
isBlock: false,
type: "simple",
storageClassType: "string",
},
condition: {
value: cdktf.listMapperHcl(wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionToHclTerraform, true)(struct.condition),
isBlock: true,
type: "set",
storageClassType: "Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionList",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.wafv2WebAclLoggingConfigurationLoggingFilterFilterToHclTerraform = wafv2WebAclLoggingConfigurationLoggingFilterFilterToHclTerraform;
class Wafv2WebAclLoggingConfigurationLoggingFilterFilterOutputReference extends cdktf.ComplexObject {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
* @param complexObjectIndex the index of this item in the list
* @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
*/
constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) {
super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex);
this.isEmptyObject = false;
// condition - computed: false, optional: false, required: true
this._condition = new Wafv2WebAclLoggingConfigurationLoggingFilterFilterConditionList(this, "condition", true);
}
get internalValue() {
if (this.resolvableValue) {
return this.resolvableValue;
}
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._behavior !== undefined) {
hasAnyValues = true;
internalValueResult.behavior = this._behavior;
}
if (this._requirement !== undefined) {
hasAnyValues = true;
internalValueResult.requirement = this._requirement;
}
if (this._condition?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.condition = this._condition?.internalValue;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this.resolvableValue = undefined;
this._behavior = undefined;
this._requirement = undefined;
this._condition.internalValue = undefined;
}
else if (cdktf.Tokenization.isResolvable(value)) {
this.isEmptyObject = false;
this.resolvableValue = value;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this.resolvableValue = undefined;
this._behavior = value.behavior;
this._requirement = value.requirement;
this._condition.internalValue = value.condition;
}
}
get behavior() {
return this.getStringAttribute('behavior');
}
set behavior(value) {
this._behavior = value;
}
// Temporarily expose input value. Use with caution.
get behaviorInput() {
return this._behavior;
}
get requirement() {
return this.getStringAttribute('requirement');
}
set requirement(value) {
this._requirement = value;
}
// Temporarily expose input value. Use with caution.
get requirementInput() {
return this._requirement;
}
get condition() {
return this._condition;
}
putCondition(value) {
this._condition.internalValue = value;
}
// Temporarily expose input value. Use with caution.
get conditionInput() {
return this._condition.internalValue;
}
}
exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterOutputReference = Wafv2WebAclLoggingConfigurationLoggingFilterFilterOutputReference;
_e = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationLoggingFilterFilterOutputReference[_e] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationLoggingFilterFilterOutputReference", version: "19.50.0" };
class Wafv2WebAclLoggingConfigurationLoggingFilterFilterList extends cdktf.ComplexList {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
* @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
*/
constructor(terraformResource, terraformAttribute, wrapsSet) {
super(terraformResource, terraformAttribute, wrapsSet);
this.terraformResource = terraformResource;
this.terraformAttribute = terraformAttribute;
this.wrapsSet = wrapsSet;
}
/**
* @param index the index of the item to return
*/
get(index) {
return new Wafv2WebAclLoggingConfigurationLoggingFilterFilterOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
}
}
exports.Wafv2WebAclLoggingConfigurationLoggingFilterFilterList = Wafv2WebAclLoggingConfigurationLoggingFilterFilterList;
_f = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationLoggingFilterFilterList[_f] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationLoggingFilterFilterList", version: "19.50.0" };
function wafv2WebAclLoggingConfigurationLoggingFilterToTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
return {
default_behavior: cdktf.stringToTerraform(struct.defaultBehavior),
filter: cdktf.listMapper(wafv2WebAclLoggingConfigurationLoggingFilterFilterToTerraform, true)(struct.filter),
};
}
exports.wafv2WebAclLoggingConfigurationLoggingFilterToTerraform = wafv2WebAclLoggingConfigurationLoggingFilterToTerraform;
function wafv2WebAclLoggingConfigurationLoggingFilterToHclTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
const attrs = {
default_behavior: {
value: cdktf.stringToHclTerraform(struct.defaultBehavior),
isBlock: false,
type: "simple",
storageClassType: "string",
},
filter: {
value: cdktf.listMapperHcl(wafv2WebAclLoggingConfigurationLoggingFilterFilterToHclTerraform, true)(struct.filter),
isBlock: true,
type: "set",
storageClassType: "Wafv2WebAclLoggingConfigurationLoggingFilterFilterList",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.wafv2WebAclLoggingConfigurationLoggingFilterToHclTerraform = wafv2WebAclLoggingConfigurationLoggingFilterToHclTerraform;
class Wafv2WebAclLoggingConfigurationLoggingFilterOutputReference extends cdktf.ComplexObject {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
*/
constructor(terraformResource, terraformAttribute) {
super(terraformResource, terraformAttribute, false, 0);
this.isEmptyObject = false;
// filter - computed: false, optional: false, required: true
this._filter = new Wafv2WebAclLoggingConfigurationLoggingFilterFilterList(this, "filter", true);
}
get internalValue() {
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._defaultBehavior !== undefined) {
hasAnyValues = true;
internalValueResult.defaultBehavior = this._defaultBehavior;
}
if (this._filter?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.filter = this._filter?.internalValue;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._defaultBehavior = undefined;
this._filter.internalValue = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._defaultBehavior = value.defaultBehavior;
this._filter.internalValue = value.filter;
}
}
get defaultBehavior() {
return this.getStringAttribute('default_behavior');
}
set defaultBehavior(value) {
this._defaultBehavior = value;
}
// Temporarily expose input value. Use with caution.
get defaultBehaviorInput() {
return this._defaultBehavior;
}
get filter() {
return this._filter;
}
putFilter(value) {
this._filter.internalValue = value;
}
// Temporarily expose input value. Use with caution.
get filterInput() {
return this._filter.internalValue;
}
}
exports.Wafv2WebAclLoggingConfigurationLoggingFilterOutputReference = Wafv2WebAclLoggingConfigurationLoggingFilterOutputReference;
_g = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationLoggingFilterOutputReference[_g] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationLoggingFilterOutputReference", version: "19.50.0" };
function wafv2WebAclLoggingConfigurationRedactedFieldsMethodToTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
return {};
}
exports.wafv2WebAclLoggingConfigurationRedactedFieldsMethodToTerraform = wafv2WebAclLoggingConfigurationRedactedFieldsMethodToTerraform;
function wafv2WebAclLoggingConfigurationRedactedFieldsMethodToHclTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
const attrs = {};
return attrs;
}
exports.wafv2WebAclLoggingConfigurationRedactedFieldsMethodToHclTerraform = wafv2WebAclLoggingConfigurationRedactedFieldsMethodToHclTerraform;
class Wafv2WebAclLoggingConfigurationRedactedFieldsMethodOutputReference extends cdktf.ComplexObject {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
*/
constructor(terraformResource, terraformAttribute) {
super(terraformResource, terraformAttribute, false, 0);
this.isEmptyObject = false;
}
get internalValue() {
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
}
}
}
exports.Wafv2WebAclLoggingConfigurationRedactedFieldsMethodOutputReference = Wafv2WebAclLoggingConfigurationRedactedFieldsMethodOutputReference;
_h = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationRedactedFieldsMethodOutputReference[_h] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationRedactedFieldsMethodOutputReference", version: "19.50.0" };
function wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringToTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
return {};
}
exports.wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringToTerraform = wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringToTerraform;
function wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringToHclTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
const attrs = {};
return attrs;
}
exports.wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringToHclTerraform = wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringToHclTerraform;
class Wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringOutputReference extends cdktf.ComplexObject {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
*/
constructor(terraformResource, terraformAttribute) {
super(terraformResource, terraformAttribute, false, 0);
this.isEmptyObject = false;
}
get internalValue() {
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
}
}
}
exports.Wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringOutputReference = Wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringOutputReference;
_j = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringOutputReference[_j] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringOutputReference", version: "19.50.0" };
function wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderToTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
return {
name: cdktf.stringToTerraform(struct.name),
};
}
exports.wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderToTerraform = wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderToTerraform;
function wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderToHclTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
const attrs = {
name: {
value: cdktf.stringToHclTerraform(struct.name),
isBlock: false,
type: "simple",
storageClassType: "string",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderToHclTerraform = wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderToHclTerraform;
class Wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderOutputReference extends cdktf.ComplexObject {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
*/
constructor(terraformResource, terraformAttribute) {
super(terraformResource, terraformAttribute, false, 0);
this.isEmptyObject = false;
}
get internalValue() {
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._name !== undefined) {
hasAnyValues = true;
internalValueResult.name = this._name;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._name = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._name = value.name;
}
}
get name() {
return this.getStringAttribute('name');
}
set name(value) {
this._name = value;
}
// Temporarily expose input value. Use with caution.
get nameInput() {
return this._name;
}
}
exports.Wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderOutputReference = Wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderOutputReference;
_k = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderOutputReference[_k] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderOutputReference", version: "19.50.0" };
function wafv2WebAclLoggingConfigurationRedactedFieldsUriPathToTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
return {};
}
exports.wafv2WebAclLoggingConfigurationRedactedFieldsUriPathToTerraform = wafv2WebAclLoggingConfigurationRedactedFieldsUriPathToTerraform;
function wafv2WebAclLoggingConfigurationRedactedFieldsUriPathToHclTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
const attrs = {};
return attrs;
}
exports.wafv2WebAclLoggingConfigurationRedactedFieldsUriPathToHclTerraform = wafv2WebAclLoggingConfigurationRedactedFieldsUriPathToHclTerraform;
class Wafv2WebAclLoggingConfigurationRedactedFieldsUriPathOutputReference extends cdktf.ComplexObject {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
*/
constructor(terraformResource, terraformAttribute) {
super(terraformResource, terraformAttribute, false, 0);
this.isEmptyObject = false;
}
get internalValue() {
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
}
}
}
exports.Wafv2WebAclLoggingConfigurationRedactedFieldsUriPathOutputReference = Wafv2WebAclLoggingConfigurationRedactedFieldsUriPathOutputReference;
_l = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationRedactedFieldsUriPathOutputReference[_l] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationRedactedFieldsUriPathOutputReference", version: "19.50.0" };
function wafv2WebAclLoggingConfigurationRedactedFieldsToTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
return {
method: wafv2WebAclLoggingConfigurationRedactedFieldsMethodToTerraform(struct.method),
query_string: wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringToTerraform(struct.queryString),
single_header: wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderToTerraform(struct.singleHeader),
uri_path: wafv2WebAclLoggingConfigurationRedactedFieldsUriPathToTerraform(struct.uriPath),
};
}
exports.wafv2WebAclLoggingConfigurationRedactedFieldsToTerraform = wafv2WebAclLoggingConfigurationRedactedFieldsToTerraform;
function wafv2WebAclLoggingConfigurationRedactedFieldsToHclTerraform(struct) {
if (!cdktf.canInspect(struct) || cdktf.Tokenization.isResolvable(struct)) {
return struct;
}
if (cdktf.isComplexElement(struct)) {
throw new Error("A complex element was used as configuration, this is not supported: https://cdk.tf/complex-object-as-configuration");
}
const attrs = {
method: {
value: wafv2WebAclLoggingConfigurationRedactedFieldsMethodToHclTerraform(struct.method),
isBlock: true,
type: "list",
storageClassType: "Wafv2WebAclLoggingConfigurationRedactedFieldsMethodList",
},
query_string: {
value: wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringToHclTerraform(struct.queryString),
isBlock: true,
type: "list",
storageClassType: "Wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringList",
},
single_header: {
value: wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderToHclTerraform(struct.singleHeader),
isBlock: true,
type: "list",
storageClassType: "Wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderList",
},
uri_path: {
value: wafv2WebAclLoggingConfigurationRedactedFieldsUriPathToHclTerraform(struct.uriPath),
isBlock: true,
type: "list",
storageClassType: "Wafv2WebAclLoggingConfigurationRedactedFieldsUriPathList",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.wafv2WebAclLoggingConfigurationRedactedFieldsToHclTerraform = wafv2WebAclLoggingConfigurationRedactedFieldsToHclTerraform;
class Wafv2WebAclLoggingConfigurationRedactedFieldsOutputReference extends cdktf.ComplexObject {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
* @param complexObjectIndex the index of this item in the list
* @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
*/
constructor(terraformResource, terraformAttribute, complexObjectIndex, complexObjectIsFromSet) {
super(terraformResource, terraformAttribute, complexObjectIsFromSet, complexObjectIndex);
this.isEmptyObject = false;
// method - computed: false, optional: true, required: false
this._method = new Wafv2WebAclLoggingConfigurationRedactedFieldsMethodOutputReference(this, "method");
// query_string - computed: false, optional: true, required: false
this._queryString = new Wafv2WebAclLoggingConfigurationRedactedFieldsQueryStringOutputReference(this, "query_string");
// single_header - computed: false, optional: true, required: false
this._singleHeader = new Wafv2WebAclLoggingConfigurationRedactedFieldsSingleHeaderOutputReference(this, "single_header");
// uri_path - computed: false, optional: true, required: false
this._uriPath = new Wafv2WebAclLoggingConfigurationRedactedFieldsUriPathOutputReference(this, "uri_path");
}
get internalValue() {
if (this.resolvableValue) {
return this.resolvableValue;
}
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._method?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.method = this._method?.internalValue;
}
if (this._queryString?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.queryString = this._queryString?.internalValue;
}
if (this._singleHeader?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.singleHeader = this._singleHeader?.internalValue;
}
if (this._uriPath?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.uriPath = this._uriPath?.internalValue;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this.resolvableValue = undefined;
this._method.internalValue = undefined;
this._queryString.internalValue = undefined;
this._singleHeader.internalValue = undefined;
this._uriPath.internalValue = undefined;
}
else if (cdktf.Tokenization.isResolvable(value)) {
this.isEmptyObject = false;
this.resolvableValue = value;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this.resolvableValue = undefined;
this._method.internalValue = value.method;
this._queryString.internalValue = value.queryString;
this._singleHeader.internalValue = value.singleHeader;
this._uriPath.internalValue = value.uriPath;
}
}
get method() {
return this._method;
}
putMethod(value) {
this._method.internalValue = value;
}
resetMethod() {
this._method.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get methodInput() {
return this._method.internalValue;
}
get queryString() {
return this._queryString;
}
putQueryString(value) {
this._queryString.internalValue = value;
}
resetQueryString() {
this._queryString.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get queryStringInput() {
return this._queryString.internalValue;
}
get singleHeader() {
return this._singleHeader;
}
putSingleHeader(value) {
this._singleHeader.internalValue = value;
}
resetSingleHeader() {
this._singleHeader.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get singleHeaderInput() {
return this._singleHeader.internalValue;
}
get uriPath() {
return this._uriPath;
}
putUriPath(value) {
this._uriPath.internalValue = value;
}
resetUriPath() {
this._uriPath.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get uriPathInput() {
return this._uriPath.internalValue;
}
}
exports.Wafv2WebAclLoggingConfigurationRedactedFieldsOutputReference = Wafv2WebAclLoggingConfigurationRedactedFieldsOutputReference;
_m = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationRedactedFieldsOutputReference[_m] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationRedactedFieldsOutputReference", version: "19.50.0" };
class Wafv2WebAclLoggingConfigurationRedactedFieldsList extends cdktf.ComplexList {
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
* @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
*/
constructor(terraformResource, terraformAttribute, wrapsSet) {
super(terraformResource, terraformAttribute, wrapsSet);
this.terraformResource = terraformResource;
this.terraformAttribute = terraformAttribute;
this.wrapsSet = wrapsSet;
}
/**
* @param index the index of the item to return
*/
get(index) {
return new Wafv2WebAclLoggingConfigurationRedactedFieldsOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
}
}
exports.Wafv2WebAclLoggingConfigurationRedactedFieldsList = Wafv2WebAclLoggingConfigurationRedactedFieldsList;
_o = JSII_RTTI_SYMBOL_1;
Wafv2WebAclLoggingConfigurationRedactedFieldsList[_o] = { fqn: "@cdktf/provider-aws.wafv2WebAclLoggingConfiguration.Wafv2WebAclLoggingConfigurationRedactedFieldsList", version: "19.50.0" };
/**
* Represents a {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/wafv2_web_acl_logging_configuration aws_wafv2_web_acl_logging_configuration}
*/
class Wafv2WebAclLoggingConfiguration extends cdktf.TerraformResource {
// ==============
// STATIC Methods
// ==============
/**
* Generates CDKTF code for importing a Wafv2WebAclLoggingConfiguration resource upon running "cdktf plan <stack-name>"
* @param scope The scope in which to define this construct
* @param importToId The construct id used in the generated config for the Wafv2WebAclLoggingConfiguration to import
* @param importFromId The id of the existing Wafv2WebAclLoggingConfiguration that should be imported. Refer to the {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/wafv2_web_acl_logging_configuration#import import section} in the documentation of this resource for the id to use
* @param provider? Optional instance of the provider where the Wafv2WebAclLoggingConfiguration to import is found
*/
static generateConfigForImport(scope, importToId, importFromId, provider) {
return new cdktf.ImportableResource(scope, importToId, { terraformResourceType: "aws_wafv2_web_acl_logging_configuration", importId: importFromId, provider });
}
// ===========
// INITIALIZER
// ===========
/**
* Create a new {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/wafv2_web_acl_logging_configuration aws_wafv2_web_acl_logging_configuration} Resource
*
* @param scope The scope in which to define this construct
* @param id The scoped construct ID. Must be unique amongst siblings in the same scope
* @param options Wafv2WebAclLoggingConfigurationConfig
*/
constructor(scope