@cdktf/provider-azurerm
Version:
Prebuilt azurerm Provider for Terraform CDK (cdktf)
1,174 lines (1,173 loc) • 537 kB
JavaScript
"use strict";
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z;
Object.defineProperty(exports, "__esModule", { value: true });
exports.functionAppSiteConfigToHclTerraform = exports.functionAppSiteConfigToTerraform = exports.FunctionAppSiteConfigCorsOutputReference = exports.functionAppSiteConfigCorsToHclTerraform = exports.functionAppSiteConfigCorsToTerraform = exports.FunctionAppSiteConfigScmIpRestrictionList = exports.FunctionAppSiteConfigScmIpRestrictionOutputReference = exports.functionAppSiteConfigScmIpRestrictionToHclTerraform = exports.functionAppSiteConfigScmIpRestrictionToTerraform = exports.FunctionAppSiteConfigScmIpRestrictionHeadersList = exports.FunctionAppSiteConfigScmIpRestrictionHeadersOutputReference = exports.functionAppSiteConfigScmIpRestrictionHeadersToHclTerraform = exports.functionAppSiteConfigScmIpRestrictionHeadersToTerraform = exports.FunctionAppSiteConfigIpRestrictionList = exports.FunctionAppSiteConfigIpRestrictionOutputReference = exports.functionAppSiteConfigIpRestrictionToHclTerraform = exports.functionAppSiteConfigIpRestrictionToTerraform = exports.FunctionAppSiteConfigIpRestrictionHeadersList = exports.FunctionAppSiteConfigIpRestrictionHeadersOutputReference = exports.functionAppSiteConfigIpRestrictionHeadersToHclTerraform = exports.functionAppSiteConfigIpRestrictionHeadersToTerraform = exports.FunctionAppIdentityOutputReference = exports.functionAppIdentityToHclTerraform = exports.functionAppIdentityToTerraform = exports.FunctionAppConnectionStringList = exports.FunctionAppConnectionStringOutputReference = exports.functionAppConnectionStringToHclTerraform = exports.functionAppConnectionStringToTerraform = exports.FunctionAppAuthSettingsOutputReference = exports.functionAppAuthSettingsToHclTerraform = exports.functionAppAuthSettingsToTerraform = exports.FunctionAppAuthSettingsTwitterOutputReference = exports.functionAppAuthSettingsTwitterToHclTerraform = exports.functionAppAuthSettingsTwitterToTerraform = exports.FunctionAppAuthSettingsMicrosoftOutputReference = exports.functionAppAuthSettingsMicrosoftToHclTerraform = exports.functionAppAuthSettingsMicrosoftToTerraform = exports.FunctionAppAuthSettingsGoogleOutputReference = exports.functionAppAuthSettingsGoogleToHclTerraform = exports.functionAppAuthSettingsGoogleToTerraform = exports.FunctionAppAuthSettingsFacebookOutputReference = exports.functionAppAuthSettingsFacebookToHclTerraform = exports.functionAppAuthSettingsFacebookToTerraform = exports.FunctionAppAuthSettingsActiveDirectoryOutputReference = exports.functionAppAuthSettingsActiveDirectoryToHclTerraform = exports.functionAppAuthSettingsActiveDirectoryToTerraform = exports.FunctionAppSiteCredentialList = exports.FunctionAppSiteCredentialOutputReference = exports.functionAppSiteCredentialToHclTerraform = exports.functionAppSiteCredentialToTerraform = void 0;
exports.FunctionApp = exports.FunctionAppTimeoutsOutputReference = exports.functionAppTimeoutsToHclTerraform = exports.functionAppTimeoutsToTerraform = exports.FunctionAppSourceControlOutputReference = exports.functionAppSourceControlToHclTerraform = exports.functionAppSourceControlToTerraform = exports.FunctionAppSiteConfigOutputReference = void 0;
const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti");
const cdktf = require("cdktf");
function functionAppSiteCredentialToTerraform(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.functionAppSiteCredentialToTerraform = functionAppSiteCredentialToTerraform;
function functionAppSiteCredentialToHclTerraform(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.functionAppSiteCredentialToHclTerraform = functionAppSiteCredentialToHclTerraform;
class FunctionAppSiteCredentialOutputReference 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() {
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;
}
}
// password - computed: true, optional: false, required: false
get password() {
return this.getStringAttribute('password');
}
// username - computed: true, optional: false, required: false
get username() {
return this.getStringAttribute('username');
}
}
exports.FunctionAppSiteCredentialOutputReference = FunctionAppSiteCredentialOutputReference;
_a = JSII_RTTI_SYMBOL_1;
FunctionAppSiteCredentialOutputReference[_a] = { fqn: "@cdktf/provider-azurerm.functionApp.FunctionAppSiteCredentialOutputReference", version: "12.27.0" };
class FunctionAppSiteCredentialList 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 FunctionAppSiteCredentialOutputReference(this.terraformResource, this.terraformAttribute, index, this.wrapsSet);
}
}
exports.FunctionAppSiteCredentialList = FunctionAppSiteCredentialList;
_b = JSII_RTTI_SYMBOL_1;
FunctionAppSiteCredentialList[_b] = { fqn: "@cdktf/provider-azurerm.functionApp.FunctionAppSiteCredentialList", version: "12.27.0" };
function functionAppAuthSettingsActiveDirectoryToTerraform(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 {
allowed_audiences: cdktf.listMapper(cdktf.stringToTerraform, false)(struct.allowedAudiences),
client_id: cdktf.stringToTerraform(struct.clientId),
client_secret: cdktf.stringToTerraform(struct.clientSecret),
};
}
exports.functionAppAuthSettingsActiveDirectoryToTerraform = functionAppAuthSettingsActiveDirectoryToTerraform;
function functionAppAuthSettingsActiveDirectoryToHclTerraform(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 = {
allowed_audiences: {
value: cdktf.listMapperHcl(cdktf.stringToHclTerraform, false)(struct.allowedAudiences),
isBlock: false,
type: "list",
storageClassType: "stringList",
},
client_id: {
value: cdktf.stringToHclTerraform(struct.clientId),
isBlock: false,
type: "simple",
storageClassType: "string",
},
client_secret: {
value: cdktf.stringToHclTerraform(struct.clientSecret),
isBlock: false,
type: "simple",
storageClassType: "string",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.functionAppAuthSettingsActiveDirectoryToHclTerraform = functionAppAuthSettingsActiveDirectoryToHclTerraform;
class FunctionAppAuthSettingsActiveDirectoryOutputReference 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._allowedAudiences !== undefined) {
hasAnyValues = true;
internalValueResult.allowedAudiences = this._allowedAudiences;
}
if (this._clientId !== undefined) {
hasAnyValues = true;
internalValueResult.clientId = this._clientId;
}
if (this._clientSecret !== undefined) {
hasAnyValues = true;
internalValueResult.clientSecret = this._clientSecret;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._allowedAudiences = undefined;
this._clientId = undefined;
this._clientSecret = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._allowedAudiences = value.allowedAudiences;
this._clientId = value.clientId;
this._clientSecret = value.clientSecret;
}
}
get allowedAudiences() {
return this.getListAttribute('allowed_audiences');
}
set allowedAudiences(value) {
this._allowedAudiences = value;
}
resetAllowedAudiences() {
this._allowedAudiences = undefined;
}
// Temporarily expose input value. Use with caution.
get allowedAudiencesInput() {
return this._allowedAudiences;
}
get clientId() {
return this.getStringAttribute('client_id');
}
set clientId(value) {
this._clientId = value;
}
// Temporarily expose input value. Use with caution.
get clientIdInput() {
return this._clientId;
}
get clientSecret() {
return this.getStringAttribute('client_secret');
}
set clientSecret(value) {
this._clientSecret = value;
}
resetClientSecret() {
this._clientSecret = undefined;
}
// Temporarily expose input value. Use with caution.
get clientSecretInput() {
return this._clientSecret;
}
}
exports.FunctionAppAuthSettingsActiveDirectoryOutputReference = FunctionAppAuthSettingsActiveDirectoryOutputReference;
_c = JSII_RTTI_SYMBOL_1;
FunctionAppAuthSettingsActiveDirectoryOutputReference[_c] = { fqn: "@cdktf/provider-azurerm.functionApp.FunctionAppAuthSettingsActiveDirectoryOutputReference", version: "12.27.0" };
function functionAppAuthSettingsFacebookToTerraform(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 {
app_id: cdktf.stringToTerraform(struct.appId),
app_secret: cdktf.stringToTerraform(struct.appSecret),
oauth_scopes: cdktf.listMapper(cdktf.stringToTerraform, false)(struct.oauthScopes),
};
}
exports.functionAppAuthSettingsFacebookToTerraform = functionAppAuthSettingsFacebookToTerraform;
function functionAppAuthSettingsFacebookToHclTerraform(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 = {
app_id: {
value: cdktf.stringToHclTerraform(struct.appId),
isBlock: false,
type: "simple",
storageClassType: "string",
},
app_secret: {
value: cdktf.stringToHclTerraform(struct.appSecret),
isBlock: false,
type: "simple",
storageClassType: "string",
},
oauth_scopes: {
value: cdktf.listMapperHcl(cdktf.stringToHclTerraform, false)(struct.oauthScopes),
isBlock: false,
type: "list",
storageClassType: "stringList",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.functionAppAuthSettingsFacebookToHclTerraform = functionAppAuthSettingsFacebookToHclTerraform;
class FunctionAppAuthSettingsFacebookOutputReference 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._appId !== undefined) {
hasAnyValues = true;
internalValueResult.appId = this._appId;
}
if (this._appSecret !== undefined) {
hasAnyValues = true;
internalValueResult.appSecret = this._appSecret;
}
if (this._oauthScopes !== undefined) {
hasAnyValues = true;
internalValueResult.oauthScopes = this._oauthScopes;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._appId = undefined;
this._appSecret = undefined;
this._oauthScopes = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._appId = value.appId;
this._appSecret = value.appSecret;
this._oauthScopes = value.oauthScopes;
}
}
get appId() {
return this.getStringAttribute('app_id');
}
set appId(value) {
this._appId = value;
}
// Temporarily expose input value. Use with caution.
get appIdInput() {
return this._appId;
}
get appSecret() {
return this.getStringAttribute('app_secret');
}
set appSecret(value) {
this._appSecret = value;
}
// Temporarily expose input value. Use with caution.
get appSecretInput() {
return this._appSecret;
}
get oauthScopes() {
return this.getListAttribute('oauth_scopes');
}
set oauthScopes(value) {
this._oauthScopes = value;
}
resetOauthScopes() {
this._oauthScopes = undefined;
}
// Temporarily expose input value. Use with caution.
get oauthScopesInput() {
return this._oauthScopes;
}
}
exports.FunctionAppAuthSettingsFacebookOutputReference = FunctionAppAuthSettingsFacebookOutputReference;
_d = JSII_RTTI_SYMBOL_1;
FunctionAppAuthSettingsFacebookOutputReference[_d] = { fqn: "@cdktf/provider-azurerm.functionApp.FunctionAppAuthSettingsFacebookOutputReference", version: "12.27.0" };
function functionAppAuthSettingsGoogleToTerraform(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 {
client_id: cdktf.stringToTerraform(struct.clientId),
client_secret: cdktf.stringToTerraform(struct.clientSecret),
oauth_scopes: cdktf.listMapper(cdktf.stringToTerraform, false)(struct.oauthScopes),
};
}
exports.functionAppAuthSettingsGoogleToTerraform = functionAppAuthSettingsGoogleToTerraform;
function functionAppAuthSettingsGoogleToHclTerraform(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 = {
client_id: {
value: cdktf.stringToHclTerraform(struct.clientId),
isBlock: false,
type: "simple",
storageClassType: "string",
},
client_secret: {
value: cdktf.stringToHclTerraform(struct.clientSecret),
isBlock: false,
type: "simple",
storageClassType: "string",
},
oauth_scopes: {
value: cdktf.listMapperHcl(cdktf.stringToHclTerraform, false)(struct.oauthScopes),
isBlock: false,
type: "list",
storageClassType: "stringList",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.functionAppAuthSettingsGoogleToHclTerraform = functionAppAuthSettingsGoogleToHclTerraform;
class FunctionAppAuthSettingsGoogleOutputReference 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._clientId !== undefined) {
hasAnyValues = true;
internalValueResult.clientId = this._clientId;
}
if (this._clientSecret !== undefined) {
hasAnyValues = true;
internalValueResult.clientSecret = this._clientSecret;
}
if (this._oauthScopes !== undefined) {
hasAnyValues = true;
internalValueResult.oauthScopes = this._oauthScopes;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._clientId = undefined;
this._clientSecret = undefined;
this._oauthScopes = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._clientId = value.clientId;
this._clientSecret = value.clientSecret;
this._oauthScopes = value.oauthScopes;
}
}
get clientId() {
return this.getStringAttribute('client_id');
}
set clientId(value) {
this._clientId = value;
}
// Temporarily expose input value. Use with caution.
get clientIdInput() {
return this._clientId;
}
get clientSecret() {
return this.getStringAttribute('client_secret');
}
set clientSecret(value) {
this._clientSecret = value;
}
// Temporarily expose input value. Use with caution.
get clientSecretInput() {
return this._clientSecret;
}
get oauthScopes() {
return this.getListAttribute('oauth_scopes');
}
set oauthScopes(value) {
this._oauthScopes = value;
}
resetOauthScopes() {
this._oauthScopes = undefined;
}
// Temporarily expose input value. Use with caution.
get oauthScopesInput() {
return this._oauthScopes;
}
}
exports.FunctionAppAuthSettingsGoogleOutputReference = FunctionAppAuthSettingsGoogleOutputReference;
_e = JSII_RTTI_SYMBOL_1;
FunctionAppAuthSettingsGoogleOutputReference[_e] = { fqn: "@cdktf/provider-azurerm.functionApp.FunctionAppAuthSettingsGoogleOutputReference", version: "12.27.0" };
function functionAppAuthSettingsMicrosoftToTerraform(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 {
client_id: cdktf.stringToTerraform(struct.clientId),
client_secret: cdktf.stringToTerraform(struct.clientSecret),
oauth_scopes: cdktf.listMapper(cdktf.stringToTerraform, false)(struct.oauthScopes),
};
}
exports.functionAppAuthSettingsMicrosoftToTerraform = functionAppAuthSettingsMicrosoftToTerraform;
function functionAppAuthSettingsMicrosoftToHclTerraform(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 = {
client_id: {
value: cdktf.stringToHclTerraform(struct.clientId),
isBlock: false,
type: "simple",
storageClassType: "string",
},
client_secret: {
value: cdktf.stringToHclTerraform(struct.clientSecret),
isBlock: false,
type: "simple",
storageClassType: "string",
},
oauth_scopes: {
value: cdktf.listMapperHcl(cdktf.stringToHclTerraform, false)(struct.oauthScopes),
isBlock: false,
type: "list",
storageClassType: "stringList",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.functionAppAuthSettingsMicrosoftToHclTerraform = functionAppAuthSettingsMicrosoftToHclTerraform;
class FunctionAppAuthSettingsMicrosoftOutputReference 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._clientId !== undefined) {
hasAnyValues = true;
internalValueResult.clientId = this._clientId;
}
if (this._clientSecret !== undefined) {
hasAnyValues = true;
internalValueResult.clientSecret = this._clientSecret;
}
if (this._oauthScopes !== undefined) {
hasAnyValues = true;
internalValueResult.oauthScopes = this._oauthScopes;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._clientId = undefined;
this._clientSecret = undefined;
this._oauthScopes = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._clientId = value.clientId;
this._clientSecret = value.clientSecret;
this._oauthScopes = value.oauthScopes;
}
}
get clientId() {
return this.getStringAttribute('client_id');
}
set clientId(value) {
this._clientId = value;
}
// Temporarily expose input value. Use with caution.
get clientIdInput() {
return this._clientId;
}
get clientSecret() {
return this.getStringAttribute('client_secret');
}
set clientSecret(value) {
this._clientSecret = value;
}
// Temporarily expose input value. Use with caution.
get clientSecretInput() {
return this._clientSecret;
}
get oauthScopes() {
return this.getListAttribute('oauth_scopes');
}
set oauthScopes(value) {
this._oauthScopes = value;
}
resetOauthScopes() {
this._oauthScopes = undefined;
}
// Temporarily expose input value. Use with caution.
get oauthScopesInput() {
return this._oauthScopes;
}
}
exports.FunctionAppAuthSettingsMicrosoftOutputReference = FunctionAppAuthSettingsMicrosoftOutputReference;
_f = JSII_RTTI_SYMBOL_1;
FunctionAppAuthSettingsMicrosoftOutputReference[_f] = { fqn: "@cdktf/provider-azurerm.functionApp.FunctionAppAuthSettingsMicrosoftOutputReference", version: "12.27.0" };
function functionAppAuthSettingsTwitterToTerraform(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 {
consumer_key: cdktf.stringToTerraform(struct.consumerKey),
consumer_secret: cdktf.stringToTerraform(struct.consumerSecret),
};
}
exports.functionAppAuthSettingsTwitterToTerraform = functionAppAuthSettingsTwitterToTerraform;
function functionAppAuthSettingsTwitterToHclTerraform(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 = {
consumer_key: {
value: cdktf.stringToHclTerraform(struct.consumerKey),
isBlock: false,
type: "simple",
storageClassType: "string",
},
consumer_secret: {
value: cdktf.stringToHclTerraform(struct.consumerSecret),
isBlock: false,
type: "simple",
storageClassType: "string",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.functionAppAuthSettingsTwitterToHclTerraform = functionAppAuthSettingsTwitterToHclTerraform;
class FunctionAppAuthSettingsTwitterOutputReference 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._consumerKey !== undefined) {
hasAnyValues = true;
internalValueResult.consumerKey = this._consumerKey;
}
if (this._consumerSecret !== undefined) {
hasAnyValues = true;
internalValueResult.consumerSecret = this._consumerSecret;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._consumerKey = undefined;
this._consumerSecret = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._consumerKey = value.consumerKey;
this._consumerSecret = value.consumerSecret;
}
}
get consumerKey() {
return this.getStringAttribute('consumer_key');
}
set consumerKey(value) {
this._consumerKey = value;
}
// Temporarily expose input value. Use with caution.
get consumerKeyInput() {
return this._consumerKey;
}
get consumerSecret() {
return this.getStringAttribute('consumer_secret');
}
set consumerSecret(value) {
this._consumerSecret = value;
}
// Temporarily expose input value. Use with caution.
get consumerSecretInput() {
return this._consumerSecret;
}
}
exports.FunctionAppAuthSettingsTwitterOutputReference = FunctionAppAuthSettingsTwitterOutputReference;
_g = JSII_RTTI_SYMBOL_1;
FunctionAppAuthSettingsTwitterOutputReference[_g] = { fqn: "@cdktf/provider-azurerm.functionApp.FunctionAppAuthSettingsTwitterOutputReference", version: "12.27.0" };
function functionAppAuthSettingsToTerraform(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 {
additional_login_params: cdktf.hashMapper(cdktf.stringToTerraform)(struct.additionalLoginParams),
allowed_external_redirect_urls: cdktf.listMapper(cdktf.stringToTerraform, false)(struct.allowedExternalRedirectUrls),
default_provider: cdktf.stringToTerraform(struct.defaultProvider),
enabled: cdktf.booleanToTerraform(struct.enabled),
issuer: cdktf.stringToTerraform(struct.issuer),
runtime_version: cdktf.stringToTerraform(struct.runtimeVersion),
token_refresh_extension_hours: cdktf.numberToTerraform(struct.tokenRefreshExtensionHours),
token_store_enabled: cdktf.booleanToTerraform(struct.tokenStoreEnabled),
unauthenticated_client_action: cdktf.stringToTerraform(struct.unauthenticatedClientAction),
active_directory: functionAppAuthSettingsActiveDirectoryToTerraform(struct.activeDirectory),
facebook: functionAppAuthSettingsFacebookToTerraform(struct.facebook),
google: functionAppAuthSettingsGoogleToTerraform(struct.google),
microsoft: functionAppAuthSettingsMicrosoftToTerraform(struct.microsoft),
twitter: functionAppAuthSettingsTwitterToTerraform(struct.twitter),
};
}
exports.functionAppAuthSettingsToTerraform = functionAppAuthSettingsToTerraform;
function functionAppAuthSettingsToHclTerraform(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 = {
additional_login_params: {
value: cdktf.hashMapperHcl(cdktf.stringToHclTerraform)(struct.additionalLoginParams),
isBlock: false,
type: "map",
storageClassType: "stringMap",
},
allowed_external_redirect_urls: {
value: cdktf.listMapperHcl(cdktf.stringToHclTerraform, false)(struct.allowedExternalRedirectUrls),
isBlock: false,
type: "list",
storageClassType: "stringList",
},
default_provider: {
value: cdktf.stringToHclTerraform(struct.defaultProvider),
isBlock: false,
type: "simple",
storageClassType: "string",
},
enabled: {
value: cdktf.booleanToHclTerraform(struct.enabled),
isBlock: false,
type: "simple",
storageClassType: "boolean",
},
issuer: {
value: cdktf.stringToHclTerraform(struct.issuer),
isBlock: false,
type: "simple",
storageClassType: "string",
},
runtime_version: {
value: cdktf.stringToHclTerraform(struct.runtimeVersion),
isBlock: false,
type: "simple",
storageClassType: "string",
},
token_refresh_extension_hours: {
value: cdktf.numberToHclTerraform(struct.tokenRefreshExtensionHours),
isBlock: false,
type: "simple",
storageClassType: "number",
},
token_store_enabled: {
value: cdktf.booleanToHclTerraform(struct.tokenStoreEnabled),
isBlock: false,
type: "simple",
storageClassType: "boolean",
},
unauthenticated_client_action: {
value: cdktf.stringToHclTerraform(struct.unauthenticatedClientAction),
isBlock: false,
type: "simple",
storageClassType: "string",
},
active_directory: {
value: functionAppAuthSettingsActiveDirectoryToHclTerraform(struct.activeDirectory),
isBlock: true,
type: "list",
storageClassType: "FunctionAppAuthSettingsActiveDirectoryList",
},
facebook: {
value: functionAppAuthSettingsFacebookToHclTerraform(struct.facebook),
isBlock: true,
type: "list",
storageClassType: "FunctionAppAuthSettingsFacebookList",
},
google: {
value: functionAppAuthSettingsGoogleToHclTerraform(struct.google),
isBlock: true,
type: "list",
storageClassType: "FunctionAppAuthSettingsGoogleList",
},
microsoft: {
value: functionAppAuthSettingsMicrosoftToHclTerraform(struct.microsoft),
isBlock: true,
type: "list",
storageClassType: "FunctionAppAuthSettingsMicrosoftList",
},
twitter: {
value: functionAppAuthSettingsTwitterToHclTerraform(struct.twitter),
isBlock: true,
type: "list",
storageClassType: "FunctionAppAuthSettingsTwitterList",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.functionAppAuthSettingsToHclTerraform = functionAppAuthSettingsToHclTerraform;
class FunctionAppAuthSettingsOutputReference 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;
// active_directory - computed: false, optional: true, required: false
this._activeDirectory = new FunctionAppAuthSettingsActiveDirectoryOutputReference(this, "active_directory");
// facebook - computed: false, optional: true, required: false
this._facebook = new FunctionAppAuthSettingsFacebookOutputReference(this, "facebook");
// google - computed: false, optional: true, required: false
this._google = new FunctionAppAuthSettingsGoogleOutputReference(this, "google");
// microsoft - computed: false, optional: true, required: false
this._microsoft = new FunctionAppAuthSettingsMicrosoftOutputReference(this, "microsoft");
// twitter - computed: false, optional: true, required: false
this._twitter = new FunctionAppAuthSettingsTwitterOutputReference(this, "twitter");
}
get internalValue() {
let hasAnyValues = this.isEmptyObject;
const internalValueResult = {};
if (this._additionalLoginParams !== undefined) {
hasAnyValues = true;
internalValueResult.additionalLoginParams = this._additionalLoginParams;
}
if (this._allowedExternalRedirectUrls !== undefined) {
hasAnyValues = true;
internalValueResult.allowedExternalRedirectUrls = this._allowedExternalRedirectUrls;
}
if (this._defaultProvider !== undefined) {
hasAnyValues = true;
internalValueResult.defaultProvider = this._defaultProvider;
}
if (this._enabled !== undefined) {
hasAnyValues = true;
internalValueResult.enabled = this._enabled;
}
if (this._issuer !== undefined) {
hasAnyValues = true;
internalValueResult.issuer = this._issuer;
}
if (this._runtimeVersion !== undefined) {
hasAnyValues = true;
internalValueResult.runtimeVersion = this._runtimeVersion;
}
if (this._tokenRefreshExtensionHours !== undefined) {
hasAnyValues = true;
internalValueResult.tokenRefreshExtensionHours = this._tokenRefreshExtensionHours;
}
if (this._tokenStoreEnabled !== undefined) {
hasAnyValues = true;
internalValueResult.tokenStoreEnabled = this._tokenStoreEnabled;
}
if (this._unauthenticatedClientAction !== undefined) {
hasAnyValues = true;
internalValueResult.unauthenticatedClientAction = this._unauthenticatedClientAction;
}
if (this._activeDirectory?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.activeDirectory = this._activeDirectory?.internalValue;
}
if (this._facebook?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.facebook = this._facebook?.internalValue;
}
if (this._google?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.google = this._google?.internalValue;
}
if (this._microsoft?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.microsoft = this._microsoft?.internalValue;
}
if (this._twitter?.internalValue !== undefined) {
hasAnyValues = true;
internalValueResult.twitter = this._twitter?.internalValue;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;
this._additionalLoginParams = undefined;
this._allowedExternalRedirectUrls = undefined;
this._defaultProvider = undefined;
this._enabled = undefined;
this._issuer = undefined;
this._runtimeVersion = undefined;
this._tokenRefreshExtensionHours = undefined;
this._tokenStoreEnabled = undefined;
this._unauthenticatedClientAction = undefined;
this._activeDirectory.internalValue = undefined;
this._facebook.internalValue = undefined;
this._google.internalValue = undefined;
this._microsoft.internalValue = undefined;
this._twitter.internalValue = undefined;
}
else {
this.isEmptyObject = Object.keys(value).length === 0;
this._additionalLoginParams = value.additionalLoginParams;
this._allowedExternalRedirectUrls = value.allowedExternalRedirectUrls;
this._defaultProvider = value.defaultProvider;
this._enabled = value.enabled;
this._issuer = value.issuer;
this._runtimeVersion = value.runtimeVersion;
this._tokenRefreshExtensionHours = value.tokenRefreshExtensionHours;
this._tokenStoreEnabled = value.tokenStoreEnabled;
this._unauthenticatedClientAction = value.unauthenticatedClientAction;
this._activeDirectory.internalValue = value.activeDirectory;
this._facebook.internalValue = value.facebook;
this._google.internalValue = value.google;
this._microsoft.internalValue = value.microsoft;
this._twitter.internalValue = value.twitter;
}
}
get additionalLoginParams() {
return this.getStringMapAttribute('additional_login_params');
}
set additionalLoginParams(value) {
this._additionalLoginParams = value;
}
resetAdditionalLoginParams() {
this._additionalLoginParams = undefined;
}
// Temporarily expose input value. Use with caution.
get additionalLoginParamsInput() {
return this._additionalLoginParams;
}
get allowedExternalRedirectUrls() {
return this.getListAttribute('allowed_external_redirect_urls');
}
set allowedExternalRedirectUrls(value) {
this._allowedExternalRedirectUrls = value;
}
resetAllowedExternalRedirectUrls() {
this._allowedExternalRedirectUrls = undefined;
}
// Temporarily expose input value. Use with caution.
get allowedExternalRedirectUrlsInput() {
return this._allowedExternalRedirectUrls;
}
get defaultProvider() {
return this.getStringAttribute('default_provider');
}
set defaultProvider(value) {
this._defaultProvider = value;
}
resetDefaultProvider() {
this._defaultProvider = undefined;
}
// Temporarily expose input value. Use with caution.
get defaultProviderInput() {
return this._defaultProvider;
}
get enabled() {
return this.getBooleanAttribute('enabled');
}
set enabled(value) {
this._enabled = value;
}
// Temporarily expose input value. Use with caution.
get enabledInput() {
return this._enabled;
}
get issuer() {
return this.getStringAttribute('issuer');
}
set issuer(value) {
this._issuer = value;
}
resetIssuer() {
this._issuer = undefined;
}
// Temporarily expose input value. Use with caution.
get issuerInput() {
return this._issuer;
}
get runtimeVersion() {
return this.getStringAttribute('runtime_version');
}
set runtimeVersion(value) {
this._runtimeVersion = value;
}
resetRuntimeVersion() {
this._runtimeVersion = undefined;
}
// Temporarily expose input value. Use with caution.
get runtimeVersionInput() {
return this._runtimeVersion;
}
get tokenRefreshExtensionHours() {
return this.getNumberAttribute('token_refresh_extension_hours');
}
set tokenRefreshExtensionHours(value) {
this._tokenRefreshExtensionHours = value;
}
resetTokenRefreshExtensionHours() {
this._tokenRefreshExtensionHours = undefined;
}
// Temporarily expose input value. Use with caution.
get tokenRefreshExtensionHoursInput() {
return this._tokenRefreshExtensionHours;
}
get tokenStoreEnabled() {
return this.getBooleanAttribute('token_store_enabled');
}
set tokenStoreEnabled(value) {
this._tokenStoreEnabled = value;
}
resetTokenStoreEnabled() {
this._tokenStoreEnabled = undefined;
}
// Temporarily expose input value. Use with caution.
get tokenStoreEnabledInput() {
return this._tokenStoreEnabled;
}
get unauthenticatedClientAction() {
return this.getStringAttribute('unauthenticated_client_action');
}
set unauthenticatedClientAction(value) {
this._unauthenticatedClientAction = value;
}
resetUnauthenticatedClientAction() {
this._unauthenticatedClientAction = undefined;
}
// Temporarily expose input value. Use with caution.
get unauthenticatedClientActionInput() {
return this._unauthenticatedClientAction;
}
get activeDirectory() {
return this._activeDirectory;
}
putActiveDirectory(value) {
this._activeDirectory.internalValue = value;
}
resetActiveDirectory() {
this._activeDirectory.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get activeDirectoryInput() {
return this._activeDirectory.internalValue;
}
get facebook() {
return this._facebook;
}
putFacebook(value) {
this._facebook.internalValue = value;
}
resetFacebook() {
this._facebook.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get facebookInput() {
return this._facebook.internalValue;
}
get google() {
return this._google;
}
putGoogle(value) {
this._google.internalValue = value;
}
resetGoogle() {
this._google.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get googleInput() {
return this._google.internalValue;
}
get microsoft() {
return this._microsoft;
}
putMicrosoft(value) {
this._microsoft.internalValue = value;
}
resetMicrosoft() {
this._microsoft.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get microsoftInput() {
return this._microsoft.internalValue;
}
get twitter() {
return this._twitter;
}
putTwitter(value) {
this._twitter.internalValue = value;
}
resetTwitter() {
this._twitter.internalValue = undefined;
}
// Temporarily expose input value. Use with caution.
get twitterInput() {
return this._twitter.internalValue;
}
}
exports.FunctionAppAuthSettingsOutputReference = FunctionAppAuthSettingsOutputReference;
_h = JSII_RTTI_SYMBOL_1;
FunctionAppAuthSettingsOutputReference[_h] = { fqn: "@cdktf/provider-azurerm.functionApp.FunctionAppAuthSettingsOutputReference", version: "12.27.0" };
function functionAppConnectionStringToTerraform(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),
type: cdktf.stringToTerraform(struct.type),
value: cdktf.stringToTerraform(struct.value),
};
}
exports.functionAppConnectionStringToTerraform = functionAppConnectionStringToTerraform;
function functionAppConnectionStringToHclTerraform(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",
},
type: {
value: cdktf.stringToHclTerraform(struct.type),
isBlock: false,
type: "simple",
storageClassType: "string",
},
value: {
value: cdktf.stringToHclTerraform(struct.value),
isBlock: false,
type: "simple",
storageClassType: "string",
},
};
// remove undefined attributes
return Object.fromEntries(Object.entries(attrs).filter(([_, value]) => value !== undefined && value.value !== undefined));
}
exports.functionAppConnectionStringToHclTerraform = functionAppConnectionStringToHclTerraform;
class FunctionAppConnectionStringOutputReference 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._name !== undefined) {
hasAnyValues = true;
internalValueResult.name = this._name;
}
if (this._type !== undefined) {
hasAnyValues = true;
internalValueResult.type = this._type;
}
if (this._value !== undefined) {
hasAnyValues = true;
internalValueResult.value = this._value;
}
return hasAnyValues ? internalValueResult : undefined;
}
set internalValue(value) {
if (value === undefined) {
this.isEmptyObject = false;