@@ -12,7 +12,7 @@ import * as cdk_errors from "aws-cdk-lib/core/lib/errors";
1212 *
1313 * @stability experimental
1414 */
15- export interface IRoleRef extends constructs.IConstruct {
15+ export interface IRoleRef extends constructs.IConstruct, cdk.IEnvironmentAware {
1616 /**
1717 * A reference to a Role resource.
1818 */
@@ -165,7 +165,7 @@ function CfnRolePropsFromCloudFormation(properties: any): cfn_parse.FromCloudFor
165165 *
166166 * @stability experimental
167167 */
168- export interface IResourceRef extends constructs .IConstruct {
168+ export interface IResourceRef extends constructs .IConstruct , cdk . IEnvironmentAware {
169169 /**
170170 * A reference to a Resource resource.
171171 */
@@ -280,7 +280,7 @@ export interface CfnResourceProps {
280280function flattenCfnResourcePermissionProperty(props: cdk.IResolvable | CfnResource.PermissionProperty): cdk.IResolvable | CfnResource.PermissionProperty {
281281 if (cdk .isResolvableObject (props )) return props ;
282282 return {
283- " roleArn" : (props .roleArn as IRoleRef )? .roleRef ? .roleArn ?? props .roleArn
283+ " roleArn" : (props .roleArn as IRoleRef )? .roleRef ? .roleArn ?? cdk . ensureStringOrUndefined ( props .roleArn , " roleArn " , " iam.IRoleRef | string " )
284284 };
285285}
286286
@@ -391,7 +391,7 @@ import * as cdk_errors from "aws-cdk-lib/core/lib/errors";
391391 *
392392 * @stability experimental
393393 */
394- export interface IRoleRef extends constructs.IConstruct {
394+ export interface IRoleRef extends constructs.IConstruct, cdk.IEnvironmentAware {
395395 /**
396396 * A reference to a Role resource.
397397 */
@@ -544,7 +544,7 @@ function CfnRolePropsFromCloudFormation(properties: any): cfn_parse.FromCloudFor
544544 *
545545 * @stability experimental
546546 */
547- export interface IUserRef extends constructs .IConstruct {
547+ export interface IUserRef extends constructs .IConstruct , cdk . IEnvironmentAware {
548548 /**
549549 * A reference to a User resource.
550550 */
@@ -697,7 +697,7 @@ function CfnUserPropsFromCloudFormation(properties: any): cfn_parse.FromCloudFor
697697 *
698698 * @stability experimental
699699 */
700- export interface IPolicyRef extends constructs .IConstruct {
700+ export interface IPolicyRef extends constructs .IConstruct , cdk . IEnvironmentAware {
701701 /**
702702 * A reference to a Policy resource.
703703 */
@@ -752,7 +752,7 @@ export class CfnPolicy extends cdk.CfnResource implements cdk.IInspectable, IPol
752752 " properties" : props
753753 });
754754
755- this .principalArn = (props .principalArn as IRoleRef )? .roleRef ? .roleArn ?? (props .principalArn as IUserRef )? .userRef ? .userArn ?? props .principalArn ;
755+ this .principalArn = (props .principalArn as IRoleRef )? .roleRef ? .roleArn ?? (props .principalArn as IUserRef )? .userRef ? .userArn ?? cdk . ensureStringOrUndefined ( props .principalArn , " principalArn " , " iam.IRoleRef | iam.IUserRef | string " ) ;
756756 }
757757
758758 public get policyRef (): PolicyReference {
@@ -859,7 +859,7 @@ import * as cdk_errors from "aws-cdk-lib/core/lib/errors";
859859 *
860860 * @stability experimental
861861 */
862- export interface IRoleRef extends constructs.IConstruct {
862+ export interface IRoleRef extends constructs.IConstruct, cdk.IEnvironmentAware {
863863 /**
864864 * A reference to a Role resource.
865865 */
@@ -1012,7 +1012,7 @@ function CfnRolePropsFromCloudFormation(properties: any): cfn_parse.FromCloudFor
10121012 *
10131013 * @stability experimental
10141014 */
1015- export interface ITaskRef extends constructs .IConstruct {
1015+ export interface ITaskRef extends constructs .IConstruct , cdk . IEnvironmentAware {
10161016 /**
10171017 * A reference to a Task resource.
10181018 */
@@ -1127,7 +1127,7 @@ export interface CfnTaskProps {
11271127function flattenCfnTaskExecutionConfigProperty(props: CfnTask.ExecutionConfigProperty | cdk.IResolvable): CfnTask.ExecutionConfigProperty | cdk.IResolvable {
11281128 if (cdk .isResolvableObject (props )) return props ;
11291129 return {
1130- " roleArn" : (props .roleArn as IRoleRef )? .roleRef ? .roleArn ?? props .roleArn
1130+ " roleArn" : (props .roleArn as IRoleRef )? .roleRef ? .roleArn ?? cdk . ensureStringOrUndefined ( props .roleArn , " roleArn " , " iam.IRoleRef | string " )
11311131 };
11321132}
11331133
@@ -1238,7 +1238,7 @@ import * as cdk_errors from "aws-cdk-lib/core/lib/errors";
12381238 *
12391239 * @stability experimental
12401240 */
1241- export interface IRoleRef extends constructs.IConstruct {
1241+ export interface IRoleRef extends constructs.IConstruct, cdk.IEnvironmentAware {
12421242 /**
12431243 * A reference to a Role resource.
12441244 */
@@ -1391,7 +1391,7 @@ function CfnRolePropsFromCloudFormation(properties: any): cfn_parse.FromCloudFor
13911391 *
13921392 * @stability experimental
13931393 */
1394- export interface IJobRef extends constructs .IConstruct {
1394+ export interface IJobRef extends constructs .IConstruct , cdk . IEnvironmentAware {
13951395 /**
13961396 * A reference to a Job resource.
13971397 */
@@ -1523,7 +1523,7 @@ export interface CfnJobProps {
15231523function flattenCfnJobConfigProperty(props: CfnJob.ConfigProperty | cdk.IResolvable): CfnJob.ConfigProperty | cdk.IResolvable {
15241524 if (cdk .isResolvableObject (props )) return props ;
15251525 return {
1526- " roleArn" : (props .roleArn as IRoleRef )? .roleRef ? .roleArn ?? props .roleArn ,
1526+ " roleArn" : (props .roleArn as IRoleRef )? .roleRef ? .roleArn ?? cdk . ensureStringOrUndefined ( props .roleArn , " roleArn " , " iam.IRoleRef | string " ) ,
15271527 " timeout" : props .timeout
15281528 };
15291529}
@@ -1577,7 +1577,7 @@ function CfnJobConfigPropertyFromCloudFormation(properties: any): cfn_parse.From
15771577function flattenCfnJobOldConfigProperty(props : cdk .IResolvable | CfnJob .OldConfigProperty ): cdk .IResolvable | CfnJob .OldConfigProperty {
15781578 if (cdk .isResolvableObject (props )) return props ;
15791579 return {
1580- " roleArn" : (props .roleArn as IRoleRef )? .roleRef ? .roleArn ?? props .roleArn
1580+ " roleArn" : (props .roleArn as IRoleRef )? .roleRef ? .roleArn ?? cdk . ensureStringOrUndefined ( props .roleArn , " roleArn " , " iam.IRoleRef | string " )
15811581 };
15821582}
15831583
@@ -1688,7 +1688,7 @@ import * as cdk_errors from "aws-cdk-lib/core/lib/errors";
16881688 *
16891689 * @stability experimental
16901690 */
1691- export interface IRoleRef extends constructs.IConstruct {
1691+ export interface IRoleRef extends constructs.IConstruct, cdk.IEnvironmentAware {
16921692 /**
16931693 * A reference to a Role resource.
16941694 */
@@ -1841,7 +1841,7 @@ function CfnRolePropsFromCloudFormation(properties: any): cfn_parse.FromCloudFor
18411841 *
18421842 * @stability experimental
18431843 */
1844- export interface IFunctionRef extends constructs .IConstruct {
1844+ export interface IFunctionRef extends constructs .IConstruct , cdk . IEnvironmentAware {
18451845 /**
18461846 * A reference to a Function resource.
18471847 */
@@ -1896,7 +1896,7 @@ export class CfnFunction extends cdk.CfnResource implements cdk.IInspectable, IF
18961896 " properties" : props
18971897 });
18981898
1899- this .roleArn = (props .roleArn as IRoleRef )? .roleRef ? .roleArn ?? props .roleArn ;
1899+ this .roleArn = (props .roleArn as IRoleRef )? .roleRef ? .roleArn ?? cdk . ensureStringOrUndefined ( props .roleArn , " roleArn " , " iam.IRoleRef | string " ) ;
19001900 }
19011901
19021902 public get functionRef (): FunctionReference {
0 commit comments