#[non_exhaustive]pub struct PermissionModelBuilder { /* private fields */ }Expand description
A builder for PermissionModel.
Implementations§
source§impl PermissionModelBuilder
impl PermissionModelBuilder
sourcepub fn type(self, input: PermissionModelType) -> Self
pub fn type(self, input: PermissionModelType) -> Self
Defines how Resilience Hub scans your resources. It can scan for the resources by using a pre-existing role in your Amazon Web Services account, or by using the credentials of the current IAM user.
This field is required.sourcepub fn set_type(self, input: Option<PermissionModelType>) -> Self
pub fn set_type(self, input: Option<PermissionModelType>) -> Self
Defines how Resilience Hub scans your resources. It can scan for the resources by using a pre-existing role in your Amazon Web Services account, or by using the credentials of the current IAM user.
sourcepub fn get_type(&self) -> &Option<PermissionModelType>
pub fn get_type(&self) -> &Option<PermissionModelType>
Defines how Resilience Hub scans your resources. It can scan for the resources by using a pre-existing role in your Amazon Web Services account, or by using the credentials of the current IAM user.
sourcepub fn invoker_role_name(self, input: impl Into<String>) -> Self
pub fn invoker_role_name(self, input: impl Into<String>) -> Self
Existing Amazon Web Services IAM role name in the primary Amazon Web Services account that will be assumed by Resilience Hub Service Principle to obtain a read-only access to your application resources while running an assessment.
You must have iam:passRole permission for this role while creating or updating the application.
sourcepub fn set_invoker_role_name(self, input: Option<String>) -> Self
pub fn set_invoker_role_name(self, input: Option<String>) -> Self
Existing Amazon Web Services IAM role name in the primary Amazon Web Services account that will be assumed by Resilience Hub Service Principle to obtain a read-only access to your application resources while running an assessment.
You must have iam:passRole permission for this role while creating or updating the application.
sourcepub fn get_invoker_role_name(&self) -> &Option<String>
pub fn get_invoker_role_name(&self) -> &Option<String>
Existing Amazon Web Services IAM role name in the primary Amazon Web Services account that will be assumed by Resilience Hub Service Principle to obtain a read-only access to your application resources while running an assessment.
You must have iam:passRole permission for this role while creating or updating the application.
sourcepub fn cross_account_role_arns(self, input: impl Into<String>) -> Self
pub fn cross_account_role_arns(self, input: impl Into<String>) -> Self
Appends an item to cross_account_role_arns.
To override the contents of this collection use set_cross_account_role_arns.
Defines a list of role Amazon Resource Names (ARNs) to be used in other accounts. These ARNs are used for querying purposes while importing resources and assessing your application.
-
These ARNs are required only when your resources are in other accounts and you have different role name in these accounts. Else, the invoker role name will be used in the other accounts.
-
These roles must have a trust policy with
iam:AssumeRolepermission to the invoker role in the primary account.
sourcepub fn set_cross_account_role_arns(self, input: Option<Vec<String>>) -> Self
pub fn set_cross_account_role_arns(self, input: Option<Vec<String>>) -> Self
Defines a list of role Amazon Resource Names (ARNs) to be used in other accounts. These ARNs are used for querying purposes while importing resources and assessing your application.
-
These ARNs are required only when your resources are in other accounts and you have different role name in these accounts. Else, the invoker role name will be used in the other accounts.
-
These roles must have a trust policy with
iam:AssumeRolepermission to the invoker role in the primary account.
sourcepub fn get_cross_account_role_arns(&self) -> &Option<Vec<String>>
pub fn get_cross_account_role_arns(&self) -> &Option<Vec<String>>
Defines a list of role Amazon Resource Names (ARNs) to be used in other accounts. These ARNs are used for querying purposes while importing resources and assessing your application.
-
These ARNs are required only when your resources are in other accounts and you have different role name in these accounts. Else, the invoker role name will be used in the other accounts.
-
These roles must have a trust policy with
iam:AssumeRolepermission to the invoker role in the primary account.
sourcepub fn build(self) -> Result<PermissionModel, BuildError>
pub fn build(self) -> Result<PermissionModel, BuildError>
Consumes the builder and constructs a PermissionModel.
This method will fail if any of the following fields are not set:
Trait Implementations§
source§impl Clone for PermissionModelBuilder
impl Clone for PermissionModelBuilder
source§fn clone(&self) -> PermissionModelBuilder
fn clone(&self) -> PermissionModelBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for PermissionModelBuilder
impl Debug for PermissionModelBuilder
source§impl Default for PermissionModelBuilder
impl Default for PermissionModelBuilder
source§fn default() -> PermissionModelBuilder
fn default() -> PermissionModelBuilder
source§impl PartialEq for PermissionModelBuilder
impl PartialEq for PermissionModelBuilder
source§fn eq(&self, other: &PermissionModelBuilder) -> bool
fn eq(&self, other: &PermissionModelBuilder) -> bool
self and other values to be equal, and is used
by ==.