@cdktf/provider-aws
Version:
Prebuilt aws Provider for Terraform CDK (cdktf)
1,236 lines • 167 kB
JavaScript
"use strict";
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
Object.defineProperty(exports, "__esModule", { value: true });
exports.LexBot = exports.LexBotTimeoutsOutputReference = exports.lexBotTimeoutsToHclTerraform = exports.lexBotTimeoutsToTerraform = exports.LexBotIntentList = exports.LexBotIntentOutputReference = exports.lexBotIntentToHclTerraform = exports.lexBotIntentToTerraform = exports.LexBotClarificationPromptOutputReference = exports.lexBotClarificationPromptToHclTerraform = exports.lexBotClarificationPromptToTerraform = exports.LexBotClarificationPromptMessageList = exports.LexBotClarificationPromptMessageOutputReference = exports.lexBotClarificationPromptMessageToHclTerraform = exports.lexBotClarificationPromptMessageToTerraform = exports.LexBotAbortStatementOutputReference = exports.lexBotAbortStatementToHclTerraform = exports.lexBotAbortStatementToTerraform = exports.LexBotAbortStatementMessageList = exports.LexBotAbortStatementMessageOutputReference = exports.lexBotAbortStatementMessageToHclTerraform = exports.lexBotAbortStatementMessageToTerraform = void 0;
const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti");
const cdktf = require("cdktf");
function lexBotAbortStatementMessageToTerraform(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 {
content: cdktf.stringToTerraform(struct.content),
content_type: cdktf.stringToTerraform(struct.contentType),
group_number: cdktf.numberToTerraform(struct.groupNumber),
};
}
exports.lexBotAbortStatementMessageToTerraform = lexBotAbortStatementMessageToTerraform;
function lexBotAbortStatementMessageToHclTerraform(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 = {
content: {
value: cdktf.stringToHclTerraform(struct.content),
isBlock: false,
type: "simple",
storageClassType: "string",
},
content_type: {
value: cdktf.stringToHclTerraform(struct.contentType),
isBlock: false,
type: "simple",
storageClassType: "string",
},
group_number: {
value: cdktf.numberToHclTerraform(struct.groupNumber),
isBlock: false,
type: "simple",
storageClassType: "number",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.lexBotAbortStatementMessageToHclTerraform = lexBotAbortStatementMessageToHclTerraform;
class LexBotAbortStatementMessageOutputReference 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;
}
get internalValue() {
if (this.resolvableValue) {
return this.resolvableValue;
}
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._content !== undefined) {
hasAnyValues = true;
internalValueResult.content = this._content;
}
if (this._contentType !== undefined) {
hasAnyValues = true;
internalValueResult.contentType = this._contentType;
}
if (this._groupNumber !== undefined) {
hasAnyValues = true;
internalValueResult.groupNumber = this._groupNumber;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this.resolvableValue = undefined;
this._content = undefined;
this._contentType = undefined;
this._groupNumber = 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._content = value.content;
this._contentType = value.contentType;
this._groupNumber = value.groupNumber;
}
}
get content() {
return this.getStringAttribute('content');
}
set content(value) {
this._content = value;
}
// Temporarily expose input value. Use with caution.
get contentInput() {
return this._content;
}
get contentType() {
return this.getStringAttribute('content_type');
}
set contentType(value) {
this._contentType = value;
}
// Temporarily expose input value. Use with caution.
get contentTypeInput() {
return this._contentType;
}
get groupNumber() {
return this.getNumberAttribute('group_number');
}
set groupNumber(value) {
this._groupNumber = value;
}
resetGroupNumber() {
this._groupNumber = undefined;
}
// Temporarily expose input value. Use with caution.
get groupNumberInput() {
return this._groupNumber;
}
}
exports.LexBotAbortStatementMessageOutputReference = LexBotAbortStatementMessageOutputReference;
_a = JSII_RTTI_SYMBOL_1;
LexBotAbortStatementMessageOutputReference[_a] = { fqn: "@cdktf/provider-aws.lexBot.LexBotAbortStatementMessageOutputReference", version: "19.50.0" };
class LexBotAbortStatementMessageList 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 LexBotAbortStatementMessageOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
}
}
exports.LexBotAbortStatementMessageList = LexBotAbortStatementMessageList;
_b = JSII_RTTI_SYMBOL_1;
LexBotAbortStatementMessageList[_b] = { fqn: "@cdktf/provider-aws.lexBot.LexBotAbortStatementMessageList", version: "19.50.0" };
function lexBotAbortStatementToTerraform(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 {
response_card: cdktf.stringToTerraform(struct.responseCard),
message: cdktf.listMapper(lexBotAbortStatementMessageToTerraform, true)(struct.message),
};
}
exports.lexBotAbortStatementToTerraform = lexBotAbortStatementToTerraform;
function lexBotAbortStatementToHclTerraform(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 = {
response_card: {
value: cdktf.stringToHclTerraform(struct.responseCard),
isBlock: false,
type: "simple",
storageClassType: "string",
},
message: {
value: cdktf.listMapperHcl(lexBotAbortStatementMessageToHclTerraform, true)(struct.message),
isBlock: true,
type: "set",
storageClassType: "LexBotAbortStatementMessageList",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.lexBotAbortStatementToHclTerraform = lexBotAbortStatementToHclTerraform;
class LexBotAbortStatementOutputReference 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;
// message - computed: false, optional: false, required: true
this._message = new LexBotAbortStatementMessageList(this, "message", true);
}
get internalValue() {
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._responseCard !== undefined) {
hasAnyValues = true;
internalValueResult.responseCard = this._responseCard;
}
if (this._message?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.message = this._message?.internalValue;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._responseCard = undefined;
this._message.internalValue = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._responseCard = value.responseCard;
this._message.internalValue = value.message;
}
}
get responseCard() {
return this.getStringAttribute('response_card');
}
set responseCard(value) {
this._responseCard = value;
}
resetResponseCard() {
this._responseCard = undefined;
}
// Temporarily expose input value. Use with caution.
get responseCardInput() {
return this._responseCard;
}
get message() {
return this._message;
}
putMessage(value) {
this._message.internalValue = value;
}
// Temporarily expose input value. Use with caution.
get messageInput() {
return this._message.internalValue;
}
}
exports.LexBotAbortStatementOutputReference = LexBotAbortStatementOutputReference;
_c = JSII_RTTI_SYMBOL_1;
LexBotAbortStatementOutputReference[_c] = { fqn: "@cdktf/provider-aws.lexBot.LexBotAbortStatementOutputReference", version: "19.50.0" };
function lexBotClarificationPromptMessageToTerraform(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 {
content: cdktf.stringToTerraform(struct.content),
content_type: cdktf.stringToTerraform(struct.contentType),
group_number: cdktf.numberToTerraform(struct.groupNumber),
};
}
exports.lexBotClarificationPromptMessageToTerraform = lexBotClarificationPromptMessageToTerraform;
function lexBotClarificationPromptMessageToHclTerraform(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 = {
content: {
value: cdktf.stringToHclTerraform(struct.content),
isBlock: false,
type: "simple",
storageClassType: "string",
},
content_type: {
value: cdktf.stringToHclTerraform(struct.contentType),
isBlock: false,
type: "simple",
storageClassType: "string",
},
group_number: {
value: cdktf.numberToHclTerraform(struct.groupNumber),
isBlock: false,
type: "simple",
storageClassType: "number",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.lexBotClarificationPromptMessageToHclTerraform = lexBotClarificationPromptMessageToHclTerraform;
class LexBotClarificationPromptMessageOutputReference 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;
}
get internalValue() {
if (this.resolvableValue) {
return this.resolvableValue;
}
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._content !== undefined) {
hasAnyValues = true;
internalValueResult.content = this._content;
}
if (this._contentType !== undefined) {
hasAnyValues = true;
internalValueResult.contentType = this._contentType;
}
if (this._groupNumber !== undefined) {
hasAnyValues = true;
internalValueResult.groupNumber = this._groupNumber;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this.resolvableValue = undefined;
this._content = undefined;
this._contentType = undefined;
this._groupNumber = 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._content = value.content;
this._contentType = value.contentType;
this._groupNumber = value.groupNumber;
}
}
get content() {
return this.getStringAttribute('content');
}
set content(value) {
this._content = value;
}
// Temporarily expose input value. Use with caution.
get contentInput() {
return this._content;
}
get contentType() {
return this.getStringAttribute('content_type');
}
set contentType(value) {
this._contentType = value;
}
// Temporarily expose input value. Use with caution.
get contentTypeInput() {
return this._contentType;
}
get groupNumber() {
return this.getNumberAttribute('group_number');
}
set groupNumber(value) {
this._groupNumber = value;
}
resetGroupNumber() {
this._groupNumber = undefined;
}
// Temporarily expose input value. Use with caution.
get groupNumberInput() {
return this._groupNumber;
}
}
exports.LexBotClarificationPromptMessageOutputReference = LexBotClarificationPromptMessageOutputReference;
_d = JSII_RTTI_SYMBOL_1;
LexBotClarificationPromptMessageOutputReference[_d] = { fqn: "@cdktf/provider-aws.lexBot.LexBotClarificationPromptMessageOutputReference", version: "19.50.0" };
class LexBotClarificationPromptMessageList 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 LexBotClarificationPromptMessageOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
}
}
exports.LexBotClarificationPromptMessageList = LexBotClarificationPromptMessageList;
_e = JSII_RTTI_SYMBOL_1;
LexBotClarificationPromptMessageList[_e] = { fqn: "@cdktf/provider-aws.lexBot.LexBotClarificationPromptMessageList", version: "19.50.0" };
function lexBotClarificationPromptToTerraform(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 {
max_attempts: cdktf.numberToTerraform(struct.maxAttempts),
response_card: cdktf.stringToTerraform(struct.responseCard),
message: cdktf.listMapper(lexBotClarificationPromptMessageToTerraform, true)(struct.message),
};
}
exports.lexBotClarificationPromptToTerraform = lexBotClarificationPromptToTerraform;
function lexBotClarificationPromptToHclTerraform(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 = {
max_attempts: {
value: cdktf.numberToHclTerraform(struct.maxAttempts),
isBlock: false,
type: "simple",
storageClassType: "number",
},
response_card: {
value: cdktf.stringToHclTerraform(struct.responseCard),
isBlock: false,
type: "simple",
storageClassType: "string",
},
message: {
value: cdktf.listMapperHcl(lexBotClarificationPromptMessageToHclTerraform, true)(struct.message),
isBlock: true,
type: "set",
storageClassType: "LexBotClarificationPromptMessageList",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.lexBotClarificationPromptToHclTerraform = lexBotClarificationPromptToHclTerraform;
class LexBotClarificationPromptOutputReference 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;
// message - computed: false, optional: false, required: true
this._message = new LexBotClarificationPromptMessageList(this, "message", true);
}
get internalValue() {
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._maxAttempts !== undefined) {
hasAnyValues = true;
internalValueResult.maxAttempts = this._maxAttempts;
}
if (this._responseCard !== undefined) {
hasAnyValues = true;
internalValueResult.responseCard = this._responseCard;
}
if (this._message?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.message = this._message?.internalValue;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._maxAttempts = undefined;
this._responseCard = undefined;
this._message.internalValue = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._maxAttempts = value.maxAttempts;
this._responseCard = value.responseCard;
this._message.internalValue = value.message;
}
}
get maxAttempts() {
return this.getNumberAttribute('max_attempts');
}
set maxAttempts(value) {
this._maxAttempts = value;
}
// Temporarily expose input value. Use with caution.
get maxAttemptsInput() {
return this._maxAttempts;
}
get responseCard() {
return this.getStringAttribute('response_card');
}
set responseCard(value) {
this._responseCard = value;
}
resetResponseCard() {
this._responseCard = undefined;
}
// Temporarily expose input value. Use with caution.
get responseCardInput() {
return this._responseCard;
}
get message() {
return this._message;
}
putMessage(value) {
this._message.internalValue = value;
}
// Temporarily expose input value. Use with caution.
get messageInput() {
return this._message.internalValue;
}
}
exports.LexBotClarificationPromptOutputReference = LexBotClarificationPromptOutputReference;
_f = JSII_RTTI_SYMBOL_1;
LexBotClarificationPromptOutputReference[_f] = { fqn: "@cdktf/provider-aws.lexBot.LexBotClarificationPromptOutputReference", version: "19.50.0" };
function lexBotIntentToTerraform(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 {
intent_name: cdktf.stringToTerraform(struct.intentName),
intent_version: cdktf.stringToTerraform(struct.intentVersion),
};
}
exports.lexBotIntentToTerraform = lexBotIntentToTerraform;
function lexBotIntentToHclTerraform(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 = {
intent_name: {
value: cdktf.stringToHclTerraform(struct.intentName),
isBlock: false,
type: "simple",
storageClassType: "string",
},
intent_version: {
value: cdktf.stringToHclTerraform(struct.intentVersion),
isBlock: false,
type: "simple",
storageClassType: "string",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.lexBotIntentToHclTerraform = lexBotIntentToHclTerraform;
class LexBotIntentOutputReference 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;
}
get internalValue() {
if (this.resolvableValue) {
return this.resolvableValue;
}
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._intentName !== undefined) {
hasAnyValues = true;
internalValueResult.intentName = this._intentName;
}
if (this._intentVersion !== undefined) {
hasAnyValues = true;
internalValueResult.intentVersion = this._intentVersion;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this.resolvableValue = undefined;
this._intentName = undefined;
this._intentVersion = 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._intentName = value.intentName;
this._intentVersion = value.intentVersion;
}
}
get intentName() {
return this.getStringAttribute('intent_name');
}
set intentName(value) {
this._intentName = value;
}
// Temporarily expose input value. Use with caution.
get intentNameInput() {
return this._intentName;
}
get intentVersion() {
return this.getStringAttribute('intent_version');
}
set intentVersion(value) {
this._intentVersion = value;
}
// Temporarily expose input value. Use with caution.
get intentVersionInput() {
return this._intentVersion;
}
}
exports.LexBotIntentOutputReference = LexBotIntentOutputReference;
_g = JSII_RTTI_SYMBOL_1;
LexBotIntentOutputReference[_g] = { fqn: "@cdktf/provider-aws.lexBot.LexBotIntentOutputReference", version: "19.50.0" };
class LexBotIntentList 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 LexBotIntentOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
}
}
exports.LexBotIntentList = LexBotIntentList;
_h = JSII_RTTI_SYMBOL_1;
LexBotIntentList[_h] = { fqn: "@cdktf/provider-aws.lexBot.LexBotIntentList", version: "19.50.0" };
function lexBotTimeoutsToTerraform(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 {
create: cdktf.stringToTerraform(struct.create),
delete: cdktf.stringToTerraform(struct.delete),
update: cdktf.stringToTerraform(struct.update),
};
}
exports.lexBotTimeoutsToTerraform = lexBotTimeoutsToTerraform;
function lexBotTimeoutsToHclTerraform(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 = {
create: {
value: cdktf.stringToHclTerraform(struct.create),
isBlock: false,
type: "simple",
storageClassType: "string",
},
delete: {
value: cdktf.stringToHclTerraform(struct.delete),
isBlock: false,
type: "simple",
storageClassType: "string",
},
update: {
value: cdktf.stringToHclTerraform(struct.update),
isBlock: false,
type: "simple",
storageClassType: "string",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.lexBotTimeoutsToHclTerraform = lexBotTimeoutsToHclTerraform;
class LexBotTimeoutsOutputReference 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);
this.isEmptyObject = false;
}
get internalValue() {
if (this.resolvableValue) {
return this.resolvableValue;
}
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._create !== undefined) {
hasAnyValues = true;
internalValueResult.create = this._create;
}
if (this._delete !== undefined) {
hasAnyValues = true;
internalValueResult.delete = this._delete;
}
if (this._update !== undefined) {
hasAnyValues = true;
internalValueResult.update = this._update;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this.resolvableValue = undefined;
this._create = undefined;
this._delete = undefined;
this._update = 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._create = value.create;
this._delete = value.delete;
this._update = value.update;
}
}
get create() {
return this.getStringAttribute('create');
}
set create(value) {
this._create = value;
}
resetCreate() {
this._create = undefined;
}
// Temporarily expose input value. Use with caution.
get createInput() {
return this._create;
}
get delete() {
return this.getStringAttribute('delete');
}
set delete(value) {
this._delete = value;
}
resetDelete() {
this._delete = undefined;
}
// Temporarily expose input value. Use with caution.
get deleteInput() {
return this._delete;
}
get update() {
return this.getStringAttribute('update');
}
set update(value) {
this._update = value;
}
resetUpdate() {
this._update = undefined;
}
// Temporarily expose input value. Use with caution.
get updateInput() {
return this._update;
}
}
exports.LexBotTimeoutsOutputReference = LexBotTimeoutsOutputReference;
_j = JSII_RTTI_SYMBOL_1;
LexBotTimeoutsOutputReference[_j] = { fqn: "@cdktf/provider-aws.lexBot.LexBotTimeoutsOutputReference", version: "19.50.0" };
/**
* Represents a {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/lex_bot aws_lex_bot}
*/
class LexBot extends cdktf.TerraformResource {
// ==============
// STATIC Methods
// ==============
/**
* Generates CDKTF code for importing a LexBot 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 LexBot to import
* @param importFromId The id of the existing LexBot that should be imported. Refer to the {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/lex_bot#import import section} in the documentation of this resource for the id to use
* @param provider? Optional instance of the provider where the LexBot to import is found
*/
static generateConfigForImport(scope, importToId, importFromId, provider) {
return new cdktf.ImportableResource(scope, importToId, { terraformResourceType: "aws_lex_bot", importId: importFromId, provider });
}
// ===========
// INITIALIZER
// ===========
/**
* Create a new {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/lex_bot aws_lex_bot} 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 LexBotConfig
*/
constructor(scope, id, config) {
super(scope, id, {
terraformResourceType: 'aws_lex_bot',
terraformGeneratorMetadata: {
providerName: 'aws',
providerVersion: '5.84.0',
providerVersionConstraint: '~> 5.0'
},
provider: config.provider,
dependsOn: config.dependsOn,
count: config.count,
lifecycle: config.lifecycle,
provisioners: config.provisioners,
connection: config.connection,
forEach: config.forEach
});
// abort_statement - computed: false, optional: false, required: true
this._abortStatement = new LexBotAbortStatementOutputReference(this, "abort_statement");
// clarification_prompt - computed: false, optional: true, required: false
this._clarificationPrompt = new LexBotClarificationPromptOutputReference(this, "clarification_prompt");
// intent - computed: false, optional: false, required: true
this._intent = new LexBotIntentList(this, "intent", true);
// timeouts - computed: false, optional: true, required: false
this._timeouts = new LexBotTimeoutsOutputReference(this, "timeouts");
this._childDirected = config.childDirected;
this._createVersion = config.createVersion;
this._description = config.description;
this._detectSentiment = config.detectSentiment;
this._enableModelImprovements = config.enableModelImprovements;
this._id = config.id;
this._idleSessionTtlInSeconds = config.idleSessionTtlInSeconds;
this._locale = config.locale;
this._name = config.name;
this._nluIntentConfidenceThreshold = config.nluIntentConfidenceThreshold;
this._processBehavior = config.processBehavior;
this._voiceId = config.voiceId;
this._abortStatement.internalValue = config.abortStatement;
this._clarificationPrompt.internalValue = config.clarificationPrompt;
this._intent.internalValue = config.intent;
this._timeouts.internalValue = config.timeouts;
}
// ==========
// ATTRIBUTES
// ==========
// arn - computed: true, optional: false, required: false
get arn() {
return this.getStringAttribute('arn');
}
// checksum - computed: true, optional: false, required: false
get checksum() {
return this.getStringAttribute('checksum');
}
get childDirected() {
return this.getBooleanAttribute('child_directed');
}
set childDirected(value) {
this._childDirected = value;
}
// Temporarily expose input value. Use with caution.
get childDirectedInput() {
return this._childDirected;
}
get createVersion() {
return this.getBooleanAttribute('create_version');
}
set createVersion(value) {
this._createVersion = value;
}
resetCreateVersion() {
this._createVersion = undefined;
}
// Temporarily expose input value. Use with caution.
get createVersionInput() {
return this._createVersion;
}
// created_date - computed: true, optional: false, required: false
get createdDate() {
return this.getStringAttribute('created_date');
}
get description() {
return this.getStringAttribute('description');
}
set description(value) {
this._description = value;
}
resetDescription() {
this._description = undefined;
}
// Temporarily expose input value. Use with caution.
get descriptionInput() {
return this._description;
}
get detectSentiment() {
return this.getBooleanAttribute('detect_sentiment');
}
set detectSentiment(value) {
this._detectSentiment = value;
}
resetDetectSentiment() {
this._detectSentiment = undefined;
}
// Temporarily expose input value. Use with caution.
get detectSentimentInput() {
return this._detectSentiment;
}
get enableModelImprovements() {
return this.getBooleanAttribute('enable_model_improvements');
}
set enableModelImprovements(value) {
this._enableModelImprovements = value;
}
resetEnableModelImprovements() {
this._enableModelImprovements = undefined;
}
// Temporarily expose input value. Use with caution.
get enableModelImprovementsInput() {
return this._enableModelImprovements;
}
// failure_reason - computed: true, optional: false, required: false
get failureReason() {
return this.getStringAttribute('failure_reason');
}
get id() {
return this.getStringAttribute('id');
}
set id(value) {
this._id = value;
}
resetId() {
this._id = undefined;
}
// Temporarily expose input value. Use with caution.
get idInput() {
return this._id;
}
get idleSessionTtlInSeconds() {
return this.getNumberAttribute('idle_session_ttl_in_seconds');
}
set idleSessionTtlInSeconds(value) {
this._idleSessionTtlInSeconds = value;
}
resetIdleSessionTtlInSeconds() {
this._idleSessionTtlInSeconds = undefined;
}
// Temporarily expose input value. Use with caution.
get idleSessionTtlInSecondsInput() {
return this._idleSessionTtlInSeconds;
}
// last_updated_date - computed: true, optional: false, required: false
get lastUpdatedDate() {
return this.getStringAttribute('last_updated_date');
}
get locale() {
return this.getStringAttribute('locale');
}
set locale(value) {
this._locale = value;
}
resetLocale() {
this._locale = undefined;
}
// Temporarily expose input value. Use with caution.
get localeInput() {
return this._locale;
}
get name() {
return this.getStringAttribute('name');
}
set name(value) {
this._name = value;
}
// Temporarily expose input value. Use with caution.
get nameInput() {
return this._name;
}
get nluIntentConfidenceThreshold() {
return this.getNumberAttribute('nlu_intent_confidence_threshold');
}
set nluIntentConfidenceThreshold(value) {
this._nluIntentConfidenceThreshold = value;
}
resetNluIntentConfidenceThreshold() {
this._nluIntentConfidenceThreshold = undefined;
}
// Temporarily expose input value. Use with caution.
get nluIntentConfidenceThresholdInput() {
return this._nluIntentConfidenceThreshold;
}
get processBehavior() {
return this.getStringAttribute('process_behavior');
}
set processBehavior(value) {
this._processBehavior = value;
}
resetProcessBehavior() {
this._processBehavior = undefined;
}
// Temporarily expose input value. Use with caution.
get processBehaviorInput() {
return this._processBehavior;
}
// status - computed: true, optional: false, required: false
get status() {
return this.getStringAttribute('status');
}
// version - computed: true, optional: false, required: false
get version() {
return this.getStringAttribute('version');
}
get voiceId() {
return this.getStringAttribute('voice_id');
}
set voiceId(value) {
this._voiceId = value;
}
resetVoiceId() {
this._voiceId = undefined;
}
// Temporarily expose input value. Use with caution.
get voiceIdInput() {
return this._voiceId;
}
get abortStatement() {
return this._abortStatement;
}
putAbortStatement(value) {
this._abortStatement.internalValue = value;
}
// Temporarily expose input value. Use with caution.
get abortStatementInput() {
return this._abortStatement.internalValue;
}
get clarificationPrompt() {
return this._clarificationPrompt;
}
putClarificationPrompt(value) {
this._clarificationPrompt.internalValue = value;
}
resetClarificationPrompt() {
this._clarificationPrompt.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get clarificationPromptInput() {
return this._clarificationPrompt.internalValue;
}
get intent() {
return this._intent;
}
putIntent(value) {
this._intent.internalValue = value;
}
// Temporarily expose input value. Use with caution.
get intentInput() {
return this._intent.internalValue;
}
get timeouts() {
return this._timeouts;
}
putTimeouts(value) {
this._timeouts.internalValue = value;
}
resetTimeouts() {
this._timeouts.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get timeoutsInput() {
return this._timeouts.internalValue;
}
// =========
// SYNTHESIS
// =========
synthesizeAttributes() {
return {
child_directed: cdktf.booleanToTerraform(this._childDirected),
create_version: cdktf.booleanToTerraform(this._createVersion),
description: cdktf.stringToTerraform(this._description),
detect_sentiment: cdktf.booleanToTerraform(this._detectSentiment),
enable_model_improvements: cdktf.booleanToTerraform(this._enableModelImprovements),
id: cdktf.stringToTerraform(this._id),
idle_session_ttl_in_seconds: cdktf.numberToTerraform(this._idleSessionTtlInSeconds),
locale: cdktf.stringToTerraform(this._locale),
name: cdktf.stringToTerraform(this._name),
nlu_intent_confidence_threshold: cdktf.numberToTerraform(this._nluIntentConfidenceThreshold),
process_behavior: cdktf.stringToTerraform(this._processBehavior),
voice_id: cdktf.stringToTerraform(this._voiceId),
abort_statement: lexBotAbortStatementToTerraform(this._abortStatement.internalValue),
clarification_prompt: lexBotClarificationPromptToTerraform(this._clarificationPrompt.internalValue),
intent: cdktf.listMapper(lexBotIntentToTerraform, true)(this._intent.internalValue),
timeouts: lexBotTimeoutsToTerraform(this._timeouts.internalValue),
};
}
synthesizeHclAttributes() {
const attrs = {
child_directed: {
value: cdktf.booleanToHclTerraform(this._childDirected),
isBlock: false,
type: "simple",
storageClassType: "boolean",
},
create_version: {
value: cdktf.booleanToHclTerraform(this._createVersion),
isBlock: false,
type: "simple",
storageClassType: "boolean",
},
description: {
value: cdktf.stringToHclTerraform(this._description),
isBlock: false,
type: "simple",
storageClassType: "string",
},
detect_sentiment: {
value: cdktf.booleanToHclTerraform(this._detectSentiment),
isBlock: false,
type: "simple",
storageClassType: "boolean",
},
enable_model_improvements: {
value: cdktf.booleanToHclTerraform(this._enableModelImprovements),
isBlock: false,
type: "simple",
storageClassType: "boolean",
},
id: {
value: cdktf.stringToHclTerraform(this._id),
isBlock: false,
type: "simple",
storageClassType: "string",
},
idle_session_ttl_in_seconds: {
value: cdktf.numberToHclTerraform(this._idleSessionTtlInSeconds),
isBlock: false,
type: "simple",
storageClassType: "number",
},
locale: {
value: cdktf.stringToHclTerraform(this._locale),
isBlock: false,
type: "simple",
storageClassType: "string",
},
name: {
value: cdktf.stringToHclTerraform(this._name),
isBlock: false,
type: "simple",
storageClassType: "string",
},
nlu_intent_confidence_threshold: {
value: cdktf.numberToHclTerraform(this._nluIntentConfidenceThreshold),
isBlock: false,
type: "simple",
storageClassType: "number",
},
process_behavior: {
value: cdktf.stringToHclTerraform(this._processBehavior),
isBlock: false,
type: "simple",
storageClassType: "string",
},
voice_id: {
value: cdktf.stringToHclTerraform(this._voiceId),
isBlock: false,
type: "simple",
storageClassType: "string",
},
abort_statement: {
value: lexBotAbortStatementToHclTerraform(this._abortStatement.internalValue),
isBlock: true,
type: "list",
storageClassType: "LexBotAbortStatementList",
},
clarification_prompt: {
value: lexBotClarificationPromptToHclTerraform(this._clarificationPrompt.internalValue),
isBlock: true,
type: "list",
storageClassType: "LexBotClarificationPromptList",
},
intent: {
value: cdktf.listMapperHcl(lexBotIntentToHclTerraform, true)(this._intent.internalValue),
isBlock: true,
type: "set",
storageClassType: "LexBotIntentList",
},
timeouts: {
value: lexBotTimeoutsToHclTerraform(this._timeouts.internalValue),
isBlock: true,
type: "struct",
storageClassType: "LexBotTimeouts",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
}
exports.LexBot = LexBot;
_k = JSII_RTTI_SYMBOL_1;
LexBot[_k] = { fqn: "@cdktf/provider-aws.lexBot.LexBot", version: "19.50.0" };
// =================
// STATIC PROPERTIES
// =================
LexBot.tfResourceType = "aws_lex_bot";
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvbGV4LWJvdC9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7OztBQVNBLCtCQUErQjtBQWdHL0IsU0FBZ0Isc0NBQXNDLENBQUMsTUFBd0Q7SUFDN0csSUFBSSxDQUFDLEtBQUssQ0FBQyxVQUFVLENBQUMsTUFBTSxDQUFDLElBQUksS0FBSyxDQUFDLFlBQVksQ0FBQyxZQUFZLENBQUMsTUFBTSxDQUFDLEVBQUUsQ0FBQztRQUFDLE9BQU8sTUFBTSxDQUFDO0lBQUMsQ0FBQztJQUM1RixJQUFJLEtBQUssQ0FBQyxnQkFBZ0IsQ0FBQyxNQUFNLENBQUMsRUFBRSxDQUFDO1FBQ25DLE1BQU0sSUFBSSxLQUFLLENBQUMsb0hBQW9ILENBQUMsQ0FBQztJQUN4SSxDQUFDO0lBQ0QsT0FBTztRQUNMLE9BQU8sRUFBRSxLQUFLLENBQUMsaUJBQWlCLENBQUMsTUFBTyxDQUFDLE9BQU8sQ0FBQztRQUNqRCxZQUFZLEVBQUUsS0FBSyxDQUFDLGlCQUFpQixDQUFDLE1BQU8sQ0FBQyxXQUFXLENBQUM7UUFDMUQsWUFBWSxFQUFFLEtBQUssQ0FBQyxpQkFBaUIsQ0FBQyxNQUFPLENBQUMsV0FBVyxDQUFDO0tBQzNELENBQUE7QUFDSCxDQUFDO0FBVkQsd0ZBVUM7QUFHRCxTQUFnQix5Q0FBeUMsQ0FBQyxNQUF3RDtJQUNoSCxJQUFJLENBQUMsS0FBSyxDQUFDLFVBQVUsQ0FBQyxNQUFNLENBQUMsSUFBSSxLQUFLLENBQUMsWUFBWSxDQUFDLFlBQVksQ0FBQyxNQUFNLENBQUMsRUFBRSxDQUFDO1FBQUMsT0FBTyxNQUFNLENBQUM7SUFBQyxDQUFDO0lBQzVGLElBQUksS0FBSyxDQUFDLGdCQUFnQixDQUFDLE1BQU0sQ0FBQyxFQUFFLENBQUM7UUFDbkMsTUFBTSxJQUFJLEtBQUssQ0FBQyxvSEFBb0gsQ0FBQyxDQUFDO0lBQ3hJLENBQUM7SUFDRCxNQUFNLEtBQUssR0FBRztRQUNaLE9BQU8sRUFBRTtZQUNQLEtBQUssRUFB