@cdktf/provider-aws
Version:
Prebuilt aws Provider for Terraform CDK (cdktf)
1,187 lines • 172 kB
JavaScript
"use strict";
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
Object.defineProperty(exports, "__esModule", { value: true });
exports.GameliftFleet = exports.GameliftFleetTimeoutsOutputReference = exports.gameliftFleetTimeoutsToHclTerraform = exports.gameliftFleetTimeoutsToTerraform = exports.GameliftFleetRuntimeConfigurationOutputReference = exports.gameliftFleetRuntimeConfigurationToHclTerraform = exports.gameliftFleetRuntimeConfigurationToTerraform = exports.GameliftFleetRuntimeConfigurationServerProcessList = exports.GameliftFleetRuntimeConfigurationServerProcessOutputReference = exports.gameliftFleetRuntimeConfigurationServerProcessToHclTerraform = exports.gameliftFleetRuntimeConfigurationServerProcessToTerraform = exports.GameliftFleetResourceCreationLimitPolicyOutputReference = exports.gameliftFleetResourceCreationLimitPolicyToHclTerraform = exports.gameliftFleetResourceCreationLimitPolicyToTerraform = exports.GameliftFleetEc2InboundPermissionList = exports.GameliftFleetEc2InboundPermissionOutputReference = exports.gameliftFleetEc2InboundPermissionToHclTerraform = exports.gameliftFleetEc2InboundPermissionToTerraform = exports.GameliftFleetCertificateConfigurationOutputReference = exports.gameliftFleetCertificateConfigurationToHclTerraform = exports.gameliftFleetCertificateConfigurationToTerraform = void 0;
const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti");
const cdktf = require("cdktf");
function gameliftFleetCertificateConfigurationToTerraform(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 {
certificate_type: cdktf.stringToTerraform(struct.certificateType),
};
}
exports.gameliftFleetCertificateConfigurationToTerraform = gameliftFleetCertificateConfigurationToTerraform;
function gameliftFleetCertificateConfigurationToHclTerraform(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 = {
certificate_type: {
value: cdktf.stringToHclTerraform(struct.certificateType),
isBlock: false,
type: "simple",
storageClassType: "string",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.gameliftFleetCertificateConfigurationToHclTerraform = gameliftFleetCertificateConfigurationToHclTerraform;
class GameliftFleetCertificateConfigurationOutputReference 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._certificateType !== undefined) {
hasAnyValues = true;
internalValueResult.certificateType = this._certificateType;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._certificateType = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._certificateType = value.certificateType;
}
}
get certificateType() {
return this.getStringAttribute('certificate_type');
}
set certificateType(value) {
this._certificateType = value;
}
resetCertificateType() {
this._certificateType = undefined;
}
// Temporarily expose input value. Use with caution.
get certificateTypeInput() {
return this._certificateType;
}
}
exports.GameliftFleetCertificateConfigurationOutputReference = GameliftFleetCertificateConfigurationOutputReference;
_a = JSII_RTTI_SYMBOL_1;
GameliftFleetCertificateConfigurationOutputReference[_a] = { fqn: "@cdktf/provider-aws.gameliftFleet.GameliftFleetCertificateConfigurationOutputReference", version: "19.50.0" };
function gameliftFleetEc2InboundPermissionToTerraform(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 {
from_port: cdktf.numberToTerraform(struct.fromPort),
ip_range: cdktf.stringToTerraform(struct.ipRange),
protocol: cdktf.stringToTerraform(struct.protocol),
to_port: cdktf.numberToTerraform(struct.toPort),
};
}
exports.gameliftFleetEc2InboundPermissionToTerraform = gameliftFleetEc2InboundPermissionToTerraform;
function gameliftFleetEc2InboundPermissionToHclTerraform(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 = {
from_port: {
value: cdktf.numberToHclTerraform(struct.fromPort),
isBlock: false,
type: "simple",
storageClassType: "number",
},
ip_range: {
value: cdktf.stringToHclTerraform(struct.ipRange),
isBlock: false,
type: "simple",
storageClassType: "string",
},
protocol: {
value: cdktf.stringToHclTerraform(struct.protocol),
isBlock: false,
type: "simple",
storageClassType: "string",
},
to_port: {
value: cdktf.numberToHclTerraform(struct.toPort),
isBlock: false,
type: "simple",
storageClassType: "number",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.gameliftFleetEc2InboundPermissionToHclTerraform = gameliftFleetEc2InboundPermissionToHclTerraform;
class GameliftFleetEc2InboundPermissionOutputReference 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._fromPort !== undefined) {
hasAnyValues = true;
internalValueResult.fromPort = this._fromPort;
}
if (this._ipRange !== undefined) {
hasAnyValues = true;
internalValueResult.ipRange = this._ipRange;
}
if (this._protocol !== undefined) {
hasAnyValues = true;
internalValueResult.protocol = this._protocol;
}
if (this._toPort !== undefined) {
hasAnyValues = true;
internalValueResult.toPort = this._toPort;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this.resolvableValue = undefined;
this._fromPort = undefined;
this._ipRange = undefined;
this._protocol = undefined;
this._toPort = 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._fromPort = value.fromPort;
this._ipRange = value.ipRange;
this._protocol = value.protocol;
this._toPort = value.toPort;
}
}
get fromPort() {
return this.getNumberAttribute('from_port');
}
set fromPort(value) {
this._fromPort = value;
}
// Temporarily expose input value. Use with caution.
get fromPortInput() {
return this._fromPort;
}
get ipRange() {
return this.getStringAttribute('ip_range');
}
set ipRange(value) {
this._ipRange = value;
}
// Temporarily expose input value. Use with caution.
get ipRangeInput() {
return this._ipRange;
}
get protocol() {
return this.getStringAttribute('protocol');
}
set protocol(value) {
this._protocol = value;
}
// Temporarily expose input value. Use with caution.
get protocolInput() {
return this._protocol;
}
get toPort() {
return this.getNumberAttribute('to_port');
}
set toPort(value) {
this._toPort = value;
}
// Temporarily expose input value. Use with caution.
get toPortInput() {
return this._toPort;
}
}
exports.GameliftFleetEc2InboundPermissionOutputReference = GameliftFleetEc2InboundPermissionOutputReference;
_b = JSII_RTTI_SYMBOL_1;
GameliftFleetEc2InboundPermissionOutputReference[_b] = { fqn: "@cdktf/provider-aws.gameliftFleet.GameliftFleetEc2InboundPermissionOutputReference", version: "19.50.0" };
class GameliftFleetEc2InboundPermissionList 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 GameliftFleetEc2InboundPermissionOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
}
}
exports.GameliftFleetEc2InboundPermissionList = GameliftFleetEc2InboundPermissionList;
_c = JSII_RTTI_SYMBOL_1;
GameliftFleetEc2InboundPermissionList[_c] = { fqn: "@cdktf/provider-aws.gameliftFleet.GameliftFleetEc2InboundPermissionList", version: "19.50.0" };
function gameliftFleetResourceCreationLimitPolicyToTerraform(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 {
new_game_sessions_per_creator: cdktf.numberToTerraform(struct.newGameSessionsPerCreator),
policy_period_in_minutes: cdktf.numberToTerraform(struct.policyPeriodInMinutes),
};
}
exports.gameliftFleetResourceCreationLimitPolicyToTerraform = gameliftFleetResourceCreationLimitPolicyToTerraform;
function gameliftFleetResourceCreationLimitPolicyToHclTerraform(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 = {
new_game_sessions_per_creator: {
value: cdktf.numberToHclTerraform(struct.newGameSessionsPerCreator),
isBlock: false,
type: "simple",
storageClassType: "number",
},
policy_period_in_minutes: {
value: cdktf.numberToHclTerraform(struct.policyPeriodInMinutes),
isBlock: false,
type: "simple",
storageClassType: "number",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.gameliftFleetResourceCreationLimitPolicyToHclTerraform = gameliftFleetResourceCreationLimitPolicyToHclTerraform;
class GameliftFleetResourceCreationLimitPolicyOutputReference 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._newGameSessionsPerCreator !== undefined) {
hasAnyValues = true;
internalValueResult.newGameSessionsPerCreator = this._newGameSessionsPerCreator;
}
if (this._policyPeriodInMinutes !== undefined) {
hasAnyValues = true;
internalValueResult.policyPeriodInMinutes = this._policyPeriodInMinutes;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._newGameSessionsPerCreator = undefined;
this._policyPeriodInMinutes = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._newGameSessionsPerCreator = value.newGameSessionsPerCreator;
this._policyPeriodInMinutes = value.policyPeriodInMinutes;
}
}
get newGameSessionsPerCreator() {
return this.getNumberAttribute('new_game_sessions_per_creator');
}
set newGameSessionsPerCreator(value) {
this._newGameSessionsPerCreator = value;
}
resetNewGameSessionsPerCreator() {
this._newGameSessionsPerCreator = undefined;
}
// Temporarily expose input value. Use with caution.
get newGameSessionsPerCreatorInput() {
return this._newGameSessionsPerCreator;
}
get policyPeriodInMinutes() {
return this.getNumberAttribute('policy_period_in_minutes');
}
set policyPeriodInMinutes(value) {
this._policyPeriodInMinutes = value;
}
resetPolicyPeriodInMinutes() {
this._policyPeriodInMinutes = undefined;
}
// Temporarily expose input value. Use with caution.
get policyPeriodInMinutesInput() {
return this._policyPeriodInMinutes;
}
}
exports.GameliftFleetResourceCreationLimitPolicyOutputReference = GameliftFleetResourceCreationLimitPolicyOutputReference;
_d = JSII_RTTI_SYMBOL_1;
GameliftFleetResourceCreationLimitPolicyOutputReference[_d] = { fqn: "@cdktf/provider-aws.gameliftFleet.GameliftFleetResourceCreationLimitPolicyOutputReference", version: "19.50.0" };
function gameliftFleetRuntimeConfigurationServerProcessToTerraform(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 {
concurrent_executions: cdktf.numberToTerraform(struct.concurrentExecutions),
launch_path: cdktf.stringToTerraform(struct.launchPath),
parameters: cdktf.stringToTerraform(struct.parameters),
};
}
exports.gameliftFleetRuntimeConfigurationServerProcessToTerraform = gameliftFleetRuntimeConfigurationServerProcessToTerraform;
function gameliftFleetRuntimeConfigurationServerProcessToHclTerraform(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 = {
concurrent_executions: {
value: cdktf.numberToHclTerraform(struct.concurrentExecutions),
isBlock: false,
type: "simple",
storageClassType: "number",
},
launch_path: {
value: cdktf.stringToHclTerraform(struct.launchPath),
isBlock: false,
type: "simple",
storageClassType: "string",
},
parameters: {
value: cdktf.stringToHclTerraform(struct.parameters),
isBlock: false,
type: "simple",
storageClassType: "string",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.gameliftFleetRuntimeConfigurationServerProcessToHclTerraform = gameliftFleetRuntimeConfigurationServerProcessToHclTerraform;
class GameliftFleetRuntimeConfigurationServerProcessOutputReference 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._concurrentExecutions !== undefined) {
hasAnyValues = true;
internalValueResult.concurrentExecutions = this._concurrentExecutions;
}
if (this._launchPath !== undefined) {
hasAnyValues = true;
internalValueResult.launchPath = this._launchPath;
}
if (this._parameters !== undefined) {
hasAnyValues = true;
internalValueResult.parameters = this._parameters;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this.resolvableValue = undefined;
this._concurrentExecutions = undefined;
this._launchPath = undefined;
this._parameters = 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._concurrentExecutions = value.concurrentExecutions;
this._launchPath = value.launchPath;
this._parameters = value.parameters;
}
}
get concurrentExecutions() {
return this.getNumberAttribute('concurrent_executions');
}
set concurrentExecutions(value) {
this._concurrentExecutions = value;
}
// Temporarily expose input value. Use with caution.
get concurrentExecutionsInput() {
return this._concurrentExecutions;
}
get launchPath() {
return this.getStringAttribute('launch_path');
}
set launchPath(value) {
this._launchPath = value;
}
// Temporarily expose input value. Use with caution.
get launchPathInput() {
return this._launchPath;
}
get parameters() {
return this.getStringAttribute('parameters');
}
set parameters(value) {
this._parameters = value;
}
resetParameters() {
this._parameters = undefined;
}
// Temporarily expose input value. Use with caution.
get parametersInput() {
return this._parameters;
}
}
exports.GameliftFleetRuntimeConfigurationServerProcessOutputReference = GameliftFleetRuntimeConfigurationServerProcessOutputReference;
_e = JSII_RTTI_SYMBOL_1;
GameliftFleetRuntimeConfigurationServerProcessOutputReference[_e] = { fqn: "@cdktf/provider-aws.gameliftFleet.GameliftFleetRuntimeConfigurationServerProcessOutputReference", version: "19.50.0" };
class GameliftFleetRuntimeConfigurationServerProcessList 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 GameliftFleetRuntimeConfigurationServerProcessOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
}
}
exports.GameliftFleetRuntimeConfigurationServerProcessList = GameliftFleetRuntimeConfigurationServerProcessList;
_f = JSII_RTTI_SYMBOL_1;
GameliftFleetRuntimeConfigurationServerProcessList[_f] = { fqn: "@cdktf/provider-aws.gameliftFleet.GameliftFleetRuntimeConfigurationServerProcessList", version: "19.50.0" };
function gameliftFleetRuntimeConfigurationToTerraform(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 {
game_session_activation_timeout_seconds: cdktf.numberToTerraform(struct.gameSessionActivationTimeoutSeconds),
max_concurrent_game_session_activations: cdktf.numberToTerraform(struct.maxConcurrentGameSessionActivations),
server_process: cdktf.listMapper(gameliftFleetRuntimeConfigurationServerProcessToTerraform, true)(struct.serverProcess),
};
}
exports.gameliftFleetRuntimeConfigurationToTerraform = gameliftFleetRuntimeConfigurationToTerraform;
function gameliftFleetRuntimeConfigurationToHclTerraform(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 = {
game_session_activation_timeout_seconds: {
value: cdktf.numberToHclTerraform(struct.gameSessionActivationTimeoutSeconds),
isBlock: false,
type: "simple",
storageClassType: "number",
},
max_concurrent_game_session_activations: {
value: cdktf.numberToHclTerraform(struct.maxConcurrentGameSessionActivations),
isBlock: false,
type: "simple",
storageClassType: "number",
},
server_process: {
value: cdktf.listMapperHcl(gameliftFleetRuntimeConfigurationServerProcessToHclTerraform, true)(struct.serverProcess),
isBlock: true,
type: "list",
storageClassType: "GameliftFleetRuntimeConfigurationServerProcessList",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.gameliftFleetRuntimeConfigurationToHclTerraform = gameliftFleetRuntimeConfigurationToHclTerraform;
class GameliftFleetRuntimeConfigurationOutputReference 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;
// server_process - computed: false, optional: true, required: false
this._serverProcess = new GameliftFleetRuntimeConfigurationServerProcessList(this, "server_process", false);
}
get internalValue() {
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._gameSessionActivationTimeoutSeconds !== undefined) {
hasAnyValues = true;
internalValueResult.gameSessionActivationTimeoutSeconds = this._gameSessionActivationTimeoutSeconds;
}
if (this._maxConcurrentGameSessionActivations !== undefined) {
hasAnyValues = true;
internalValueResult.maxConcurrentGameSessionActivations = this._maxConcurrentGameSessionActivations;
}
if (this._serverProcess?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.serverProcess = this._serverProcess?.internalValue;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._gameSessionActivationTimeoutSeconds = undefined;
this._maxConcurrentGameSessionActivations = undefined;
this._serverProcess.internalValue = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._gameSessionActivationTimeoutSeconds = value.gameSessionActivationTimeoutSeconds;
this._maxConcurrentGameSessionActivations = value.maxConcurrentGameSessionActivations;
this._serverProcess.internalValue = value.serverProcess;
}
}
get gameSessionActivationTimeoutSeconds() {
return this.getNumberAttribute('game_session_activation_timeout_seconds');
}
set gameSessionActivationTimeoutSeconds(value) {
this._gameSessionActivationTimeoutSeconds = value;
}
resetGameSessionActivationTimeoutSeconds() {
this._gameSessionActivationTimeoutSeconds = undefined;
}
// Temporarily expose input value. Use with caution.
get gameSessionActivationTimeoutSecondsInput() {
return this._gameSessionActivationTimeoutSeconds;
}
get maxConcurrentGameSessionActivations() {
return this.getNumberAttribute('max_concurrent_game_session_activations');
}
set maxConcurrentGameSessionActivations(value) {
this._maxConcurrentGameSessionActivations = value;
}
resetMaxConcurrentGameSessionActivations() {
this._maxConcurrentGameSessionActivations = undefined;
}
// Temporarily expose input value. Use with caution.
get maxConcurrentGameSessionActivationsInput() {
return this._maxConcurrentGameSessionActivations;
}
get serverProcess() {
return this._serverProcess;
}
putServerProcess(value) {
this._serverProcess.internalValue = value;
}
resetServerProcess() {
this._serverProcess.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get serverProcessInput() {
return this._serverProcess.internalValue;
}
}
exports.GameliftFleetRuntimeConfigurationOutputReference = GameliftFleetRuntimeConfigurationOutputReference;
_g = JSII_RTTI_SYMBOL_1;
GameliftFleetRuntimeConfigurationOutputReference[_g] = { fqn: "@cdktf/provider-aws.gameliftFleet.GameliftFleetRuntimeConfigurationOutputReference", version: "19.50.0" };
function gameliftFleetTimeoutsToTerraform(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),
};
}
exports.gameliftFleetTimeoutsToTerraform = gameliftFleetTimeoutsToTerraform;
function gameliftFleetTimeoutsToHclTerraform(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",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.gameliftFleetTimeoutsToHclTerraform = gameliftFleetTimeoutsToHclTerraform;
class GameliftFleetTimeoutsOutputReference 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;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this.resolvableValue = undefined;
this._create = undefined;
this._delete = 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;
}
}
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;
}
}
exports.GameliftFleetTimeoutsOutputReference = GameliftFleetTimeoutsOutputReference;
_h = JSII_RTTI_SYMBOL_1;
GameliftFleetTimeoutsOutputReference[_h] = { fqn: "@cdktf/provider-aws.gameliftFleet.GameliftFleetTimeoutsOutputReference", version: "19.50.0" };
/**
* Represents a {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/gamelift_fleet aws_gamelift_fleet}
*/
class GameliftFleet extends cdktf.TerraformResource {
// ==============
// STATIC Methods
// ==============
/**
* Generates CDKTF code for importing a GameliftFleet 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 GameliftFleet to import
* @param importFromId The id of the existing GameliftFleet that should be imported. Refer to the {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/gamelift_fleet#import import section} in the documentation of this resource for the id to use
* @param provider? Optional instance of the provider where the GameliftFleet to import is found
*/
static generateConfigForImport(scope, importToId, importFromId, provider) {
return new cdktf.ImportableResource(scope, importToId, { terraformResourceType: "aws_gamelift_fleet", importId: importFromId, provider });
}
// ===========
// INITIALIZER
// ===========
/**
* Create a new {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/gamelift_fleet aws_gamelift_fleet} 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 GameliftFleetConfig
*/
constructor(scope, id, config) {
super(scope, id, {
terraformResourceType: 'aws_gamelift_fleet',
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
});
// certificate_configuration - computed: false, optional: true, required: false
this._certificateConfiguration = new GameliftFleetCertificateConfigurationOutputReference(this, "certificate_configuration");
// ec2_inbound_permission - computed: false, optional: true, required: false
this._ec2InboundPermission = new GameliftFleetEc2InboundPermissionList(this, "ec2_inbound_permission", true);
// resource_creation_limit_policy - computed: false, optional: true, required: false
this._resourceCreationLimitPolicy = new GameliftFleetResourceCreationLimitPolicyOutputReference(this, "resource_creation_limit_policy");
// runtime_configuration - computed: false, optional: true, required: false
this._runtimeConfiguration = new GameliftFleetRuntimeConfigurationOutputReference(this, "runtime_configuration");
// timeouts - computed: false, optional: true, required: false
this._timeouts = new GameliftFleetTimeoutsOutputReference(this, "timeouts");
this._buildId = config.buildId;
this._description = config.description;
this._ec2InstanceType = config.ec2InstanceType;
this._fleetType = config.fleetType;
this._id = config.id;
this._instanceRoleArn = config.instanceRoleArn;
this._metricGroups = config.metricGroups;
this._name = config.name;
this._newGameSessionProtectionPolicy = config.newGameSessionProtectionPolicy;
this._scriptId = config.scriptId;
this._tags = config.tags;
this._tagsAll = config.tagsAll;
this._certificateConfiguration.internalValue = config.certificateConfiguration;
this._ec2InboundPermission.internalValue = config.ec2InboundPermission;
this._resourceCreationLimitPolicy.internalValue = config.resourceCreationLimitPolicy;
this._runtimeConfiguration.internalValue = config.runtimeConfiguration;
this._timeouts.internalValue = config.timeouts;
}
// ==========
// ATTRIBUTES
// ==========
// arn - computed: true, optional: false, required: false
get arn() {
return this.getStringAttribute('arn');
}
// build_arn - computed: true, optional: false, required: false
get buildArn() {
return this.getStringAttribute('build_arn');
}
get buildId() {
return this.getStringAttribute('build_id');
}
set buildId(value) {
this._buildId = value;
}
resetBuildId() {
this._buildId = undefined;
}
// Temporarily expose input value. Use with caution.
get buildIdInput() {
return this._buildId;
}
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 ec2InstanceType() {
return this.getStringAttribute('ec2_instance_type');
}
set ec2InstanceType(value) {
this._ec2InstanceType = value;
}
// Temporarily expose input value. Use with caution.
get ec2InstanceTypeInput() {
return this._ec2InstanceType;
}
get fleetType() {
return this.getStringAttribute('fleet_type');
}
set fleetType(value) {
this._fleetType = value;
}
resetFleetType() {
this._fleetType = undefined;
}
// Temporarily expose input value. Use with caution.
get fleetTypeInput() {
return this._fleetType;
}
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 instanceRoleArn() {
return this.getStringAttribute('instance_role_arn');
}
set instanceRoleArn(value) {
this._instanceRoleArn = value;
}
resetInstanceRoleArn() {
this._instanceRoleArn = undefined;
}
// Temporarily expose input value. Use with caution.
get instanceRoleArnInput() {
return this._instanceRoleArn;
}
// log_paths - computed: true, optional: false, required: false
get logPaths() {
return this.getListAttribute('log_paths');
}
get metricGroups() {
return this.getListAttribute('metric_groups');
}
set metricGroups(value) {
this._metricGroups = value;
}
resetMetricGroups() {
this._metricGroups = undefined;
}
// Temporarily expose input value. Use with caution.
get metricGroupsInput() {
return this._metricGroups;
}
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 newGameSessionProtectionPolicy() {
return this.getStringAttribute('new_game_session_protection_policy');
}
set newGameSessionProtectionPolicy(value) {
this._newGameSessionProtectionPolicy = value;
}
resetNewGameSessionProtectionPolicy() {
this._newGameSessionProtectionPolicy = undefined;
}
// Temporarily expose input value. Use with caution.
get newGameSessionProtectionPolicyInput() {
return this._newGameSessionProtectionPolicy;
}
// operating_system - computed: true, optional: false, required: false
get operatingSystem() {
return this.getStringAttribute('operating_system');
}
// script_arn - computed: true, optional: false, required: false
get scriptArn() {
return this.getStringAttribute('script_arn');
}
get scriptId() {
return this.getStringAttribute('script_id');
}
set scriptId(value) {
this._scriptId = value;
}
resetScriptId() {
this._scriptId = undefined;
}
// Temporarily expose input value. Use with caution.
get scriptIdInput() {
return this._scriptId;
}
get tags() {
return this.getStringMapAttribute('tags');
}
set tags(value) {
this._tags = value;
}
resetTags() {
this._tags = undefined;
}
// Temporarily expose input value. Use with caution.
get tagsInput() {
return this._tags;
}
get tagsAll() {
return this.getStringMapAttribute('tags_all');
}
set tagsAll(value) {
this._tagsAll = value;
}
resetTagsAll() {
this._tagsAll = undefined;
}
// Temporarily expose input value. Use with caution.
get tagsAllInput() {
return this._tagsAll;
}
get certificateConfiguration() {
return this._certificateConfiguration;
}
putCertificateConfiguration(value) {
this._certificateConfiguration.internalValue = value;
}
resetCertificateConfiguration() {
this._certificateConfiguration.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get certificateConfigurationInput() {
return this._certificateConfiguration.internalValue;
}
get ec2InboundPermission() {
return this._ec2InboundPermission;
}
putEc2InboundPermission(value) {
this._ec2InboundPermission.internalValue = value;
}
resetEc2InboundPermission() {
this._ec2InboundPermission.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get ec2InboundPermissionInput() {
return this._ec2InboundPermission.internalValue;
}
get resourceCreationLimitPolicy() {
return this._resourceCreationLimitPolicy;
}
putResourceCreationLimitPolicy(value) {
this._resourceCreationLimitPolicy.internalValue = value;
}
resetResourceCreationLimitPolicy() {
this._resourceCreationLimitPolicy.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get resourceCreationLimitPolicyInput() {
return this._resourceCreationLimitPolicy.internalValue;
}
get runtimeConfiguration() {
return this._runtimeConfiguration;
}
putRuntimeConfiguration(value) {
this._runtimeConfiguration.internalValue = value;
}
resetRuntimeConfiguration() {
this._runtimeConfiguration.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get runtimeConfigurationInput() {
return this._runtimeConfiguration.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 {
build_id: cdktf.stringToTerraform(this._buildId),
description: cdktf.stringToTerraform(this._description),
ec2_instance_type: cdktf.stringToTerraform(this._ec2InstanceType),
fleet_type: cdktf.stringToTerraform(this._fleetType),
id: cdktf.stringToTerraform(this._id),
instance_role_arn: cdktf.stringToTerraform(this._instanceRoleArn),
metric_groups: cdktf.listMapper(cdktf.stringToTerraform, false)(this._metricGroups),
name: cdktf.stringToTerraform(this._name),
new_game_session_protection_policy: cdktf.stringToTerraform(this._newGameSessionProtectionPolicy),
script_id: cdktf.stringToTerraform(this._scriptId),
tags: cdktf.hashMapper(cdktf.stringToTerraform)(this._tags),
tags_all: cdktf.hashMapper(cdktf.stringToTerraform)(this._tagsAll),
certificate_configuration: gameliftFleetCertificateConfigurationToTerraform(this._certificateConfiguration.internalValue),
ec2_inbound_permission: cdktf.listMapper(gameliftFleetEc2InboundPermissionToTerraform, true)(this._ec2InboundPermission.internalValue),
resource_creation_limit_policy: gameliftFleetResourceCreationLimitPolicyToTerraform(this._resourceCreationLimitPolicy.internalValue),
runtime_configuration: gameliftFleetRuntimeConfigurationToTerraform(this._runtimeConfiguration.internalValue),
timeouts: gameliftFleetTimeoutsToTerraform(this._timeouts.internalValue),
};
}
synthesizeHclAttributes() {
const attrs = {
build_id: {
value: cdktf.stringToHclTerraform(this._buildId),
isBlock: false,
type: "simple",
storageClassType: "string",
},
description: {
value: cdktf.stringToHclTerraform(this._description),
isBlock: false,
type: "simple",
storageClassType: "string",
},
ec2_instance_type: {
value: cdktf.stringToHclTerraform(this._ec2InstanceType),
isBlock: false,
type: "simple",
storageClassType: "string",
},
fleet_type: {
value: cdktf.stringToHclTerraform(this._fleetType),
isBlock: false,
type: "simple",
storageClassType: "string",
},
id: {
value: cdktf.stringToHclTerraform(this._id),
isBlock: false,
type: "simple",
storageClassType: "string",
},
instance_role_arn: {
value: cdktf.stringToHclTerraform(this._instanceRoleArn),
isBlock: false,
type: "simple",
storageClassType: "string",
},
metric_groups: {
value: cdktf.listMapperHcl(cdktf.stringToHclTerraform, false)(this._metricGroups),
isBlock: false,
type: "list",
storageClassType: "stringList",
},
name: {
value: cdktf.stringToHclTerraform(this._name),
isBlock: false,
type: "simple",
storageClassType: "string",
},
new_game_session_protection_policy: {
value: cdktf.stringToHclTerraform(this._newGameSessionProtectionPolicy),
isBlock: false,
type: "simple",
storageClassType: "string",
},
script_id: {
value: cdktf.stringToHclTerraform(this._scriptId),
isBlock: false,
type: "simple",
storageClassType: "string",
},
tags: {
value: cdktf.hashMapperHcl(cdktf.stringToHclTerraform)(this._tags),
isBlock: false,
type: "map",
storageClassType: "stringMap",
},
tags_all: {
value: cdktf.hashMapperHcl(cdktf.stringToHclTerraform)(this._tagsAll),
isBlock: false,
type: "map",
storageClassType: "stringMap",
},
certificate_configuration: {
value: gameliftFleetCertificateConfigurationToHclTerraform(this._certificateConfiguration.internalValue),
isBlock: true,
type: "list",
storageClassType: "GameliftFleetCertificateConfigurationList",
},
ec2_inbound_permission: {
value: cdktf.listMapperHcl(gameliftFleetEc2InboundPermissionToHclTerraform, true)(this._ec2InboundPermission.internalValue),
isBlock: true,
type: "set",
storageClassType: "GameliftFleetEc2InboundPermissionList",
},
resource_creation_limit_policy: {
value: gameliftFleetResourceCreationLimitPolicyToHclTerraform(this._resourceCreationLimitPolicy.internalValue),
isBlock: true,
type: "list",
storageClassType: "GameliftFleetResourceCreationLimitPolicyList",
},
runtime_configuration: {
value: gameliftFleetRuntimeConfigurationToHclTerraform(this._runtimeConfiguration.internalValue),
isBlock: true,
type: "list",
storageClassType: "GameliftFleetRuntimeConfigurationList",
},
timeouts: