pub struct BindingExplanation {
pub access: i32,
pub role: String,
pub role_permission: i32,
pub role_permission_relevance: i32,
pub memberships: HashMap<String, AnnotatedMembership>,
pub relevance: i32,
pub condition: Option<Expr>,
}
Expand description
Details about how a binding in a policy affects a member’s ability to use a permission.
Fields§
§access: i32
Required. Indicates whether this binding provides the specified permission to the specified member for the specified resource.
This field does not indicate whether the member actually has the
permission for the resource. There might be another binding that overrides
this binding. To determine whether the member actually has the permission,
use the access
field in the
[TroubleshootIamPolicyResponse][IamChecker.TroubleshootIamPolicyResponse].
role: String
The role that this binding grants. For example,
roles/compute.serviceAgent
.
For a complete list of predefined IAM roles, as well as the permissions in each role, see https://cloud.google.com/iam/help/roles/reference.
role_permission: i32
Indicates whether the role granted by this binding contains the specified permission.
role_permission_relevance: i32
The relevance of the permission’s existence, or nonexistence, in the role to the overall determination for the entire policy.
memberships: HashMap<String, AnnotatedMembership>
Indicates whether each member in the binding includes the member specified in the request, either directly or indirectly. Each key identifies a member in the binding, and each value indicates whether the member in the binding includes the member in the request.
For example, suppose that a binding includes the following members:
user:alice@example.com
group:product-eng@example.com
You want to troubleshoot access for user:bob@example.com
. This user is a
member of the group group:product-eng@example.com
.
For the first member in the binding, the key is user:alice@example.com
,
and the membership
field in the value is set to
MEMBERSHIP_NOT_INCLUDED
.
For the second member in the binding, the key is
group:product-eng@example.com
, and the membership
field in the value is
set to MEMBERSHIP_INCLUDED
.
relevance: i32
The relevance of this binding to the overall determination for the entire policy.
condition: Option<Expr>
A condition expression that prevents access unless the expression evaluates
to true
.
To learn about IAM Conditions, see http://cloud.google.com/iam/help/conditions/overview.
Implementations§
Source§impl BindingExplanation
impl BindingExplanation
Sourcepub fn access(&self) -> AccessState
pub fn access(&self) -> AccessState
Returns the enum value of access
, or the default if the field is set to an invalid enum value.
Sourcepub fn set_access(&mut self, value: AccessState)
pub fn set_access(&mut self, value: AccessState)
Sets access
to the provided enum value.
Sourcepub fn role_permission(&self) -> RolePermission
pub fn role_permission(&self) -> RolePermission
Returns the enum value of role_permission
, or the default if the field is set to an invalid enum value.
Sourcepub fn set_role_permission(&mut self, value: RolePermission)
pub fn set_role_permission(&mut self, value: RolePermission)
Sets role_permission
to the provided enum value.
Sourcepub fn role_permission_relevance(&self) -> HeuristicRelevance
pub fn role_permission_relevance(&self) -> HeuristicRelevance
Returns the enum value of role_permission_relevance
, or the default if the field is set to an invalid enum value.
Sourcepub fn set_role_permission_relevance(&mut self, value: HeuristicRelevance)
pub fn set_role_permission_relevance(&mut self, value: HeuristicRelevance)
Sets role_permission_relevance
to the provided enum value.
Sourcepub fn relevance(&self) -> HeuristicRelevance
pub fn relevance(&self) -> HeuristicRelevance
Returns the enum value of relevance
, or the default if the field is set to an invalid enum value.
Sourcepub fn set_relevance(&mut self, value: HeuristicRelevance)
pub fn set_relevance(&mut self, value: HeuristicRelevance)
Sets relevance
to the provided enum value.
Trait Implementations§
Source§impl Clone for BindingExplanation
impl Clone for BindingExplanation
Source§fn clone(&self) -> BindingExplanation
fn clone(&self) -> BindingExplanation
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for BindingExplanation
impl Debug for BindingExplanation
Source§impl Default for BindingExplanation
impl Default for BindingExplanation
Source§fn default() -> BindingExplanation
fn default() -> BindingExplanation
Source§impl Message for BindingExplanation
impl Message for BindingExplanation
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Source§fn decode<B>(buf: B) -> Result<Self, DecodeError>
fn decode<B>(buf: B) -> Result<Self, DecodeError>
Source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
Source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
self
. Read moreSource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
self
.Source§impl PartialEq for BindingExplanation
impl PartialEq for BindingExplanation
impl StructuralPartialEq for BindingExplanation
Auto Trait Implementations§
impl Freeze for BindingExplanation
impl RefUnwindSafe for BindingExplanation
impl Send for BindingExplanation
impl Sync for BindingExplanation
impl Unpin for BindingExplanation
impl UnwindSafe for BindingExplanation
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request