Class ExplainedAllowPolicy.Builder (1.53.0)

public static final class ExplainedAllowPolicy.Builder extends GeneratedMessageV3.Builder<ExplainedAllowPolicy.Builder> implements ExplainedAllowPolicyOrBuilder

Details about how a specific IAM allow policy contributed to the final access state.

Protobuf type google.cloud.policytroubleshooter.iam.v3.ExplainedAllowPolicy

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addAllBindingExplanations(Iterable<? extends AllowBindingExplanation> values)

public ExplainedAllowPolicy.Builder addAllBindingExplanations(Iterable<? extends AllowBindingExplanation> values)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameter
Name Description
values Iterable<? extends com.google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation>
Returns
Type Description
ExplainedAllowPolicy.Builder

addBindingExplanations(AllowBindingExplanation value)

public ExplainedAllowPolicy.Builder addBindingExplanations(AllowBindingExplanation value)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameter
Name Description
value AllowBindingExplanation
Returns
Type Description
ExplainedAllowPolicy.Builder

addBindingExplanations(AllowBindingExplanation.Builder builderForValue)

public ExplainedAllowPolicy.Builder addBindingExplanations(AllowBindingExplanation.Builder builderForValue)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameter
Name Description
builderForValue AllowBindingExplanation.Builder
Returns
Type Description
ExplainedAllowPolicy.Builder

addBindingExplanations(int index, AllowBindingExplanation value)

public ExplainedAllowPolicy.Builder addBindingExplanations(int index, AllowBindingExplanation value)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameters
Name Description
index int
value AllowBindingExplanation
Returns
Type Description
ExplainedAllowPolicy.Builder

addBindingExplanations(int index, AllowBindingExplanation.Builder builderForValue)

public ExplainedAllowPolicy.Builder addBindingExplanations(int index, AllowBindingExplanation.Builder builderForValue)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameters
Name Description
index int
builderForValue AllowBindingExplanation.Builder
Returns
Type Description
ExplainedAllowPolicy.Builder

addBindingExplanationsBuilder()

public AllowBindingExplanation.Builder addBindingExplanationsBuilder()

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Returns
Type Description
AllowBindingExplanation.Builder

addBindingExplanationsBuilder(int index)

public AllowBindingExplanation.Builder addBindingExplanationsBuilder(int index)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameter
Name Description
index int
Returns
Type Description
AllowBindingExplanation.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public ExplainedAllowPolicy.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
ExplainedAllowPolicy.Builder
Overrides

build()

public ExplainedAllowPolicy build()
Returns
Type Description
ExplainedAllowPolicy

buildPartial()

public ExplainedAllowPolicy buildPartial()
Returns
Type Description
ExplainedAllowPolicy

clear()

public ExplainedAllowPolicy.Builder clear()
Returns
Type Description
ExplainedAllowPolicy.Builder
Overrides

clearAllowAccessState()

public ExplainedAllowPolicy.Builder clearAllowAccessState()

Required. Indicates whether this policy provides the specified permission to the specified principal for the specified resource.

This field does not indicate whether the principal actually has the permission for the resource. There might be another policy that overrides this policy. To determine whether the principal actually has the permission, use the overall_access_state field in the TroubleshootIamPolicyResponse.

.google.cloud.policytroubleshooter.iam.v3.AllowAccessState allow_access_state = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ExplainedAllowPolicy.Builder

This builder for chaining.

clearBindingExplanations()

public ExplainedAllowPolicy.Builder clearBindingExplanations()

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Returns
Type Description
ExplainedAllowPolicy.Builder

clearField(Descriptors.FieldDescriptor field)

public ExplainedAllowPolicy.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
ExplainedAllowPolicy.Builder
Overrides

clearFullResourceName()

public ExplainedAllowPolicy.Builder clearFullResourceName()

The full resource name that identifies the resource. For example, //compute.googleapis.com/projects/my-project/zones/us-central1-a/instances/my-instance.

If the sender of the request does not have access to the policy, this field is omitted.

For examples of full resource names for Google Cloud services, see https://cloud.google.com/iam/help/troubleshooter/full-resource-names.

string full_resource_name = 2;

Returns
Type Description
ExplainedAllowPolicy.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public ExplainedAllowPolicy.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
ExplainedAllowPolicy.Builder
Overrides

clearPolicy()

public ExplainedAllowPolicy.Builder clearPolicy()

The IAM allow policy attached to the resource.

If the sender of the request does not have access to the policy, this field is empty.

.google.iam.v1.Policy policy = 5;

Returns
Type Description
ExplainedAllowPolicy.Builder

clearRelevance()

public ExplainedAllowPolicy.Builder clearRelevance()

The relevance of this policy to the overall access state in the TroubleshootIamPolicyResponse.

If the sender of the request does not have access to the policy, this field is omitted.

.google.cloud.policytroubleshooter.iam.v3.HeuristicRelevance relevance = 4;

Returns
Type Description
ExplainedAllowPolicy.Builder

This builder for chaining.

clone()

public ExplainedAllowPolicy.Builder clone()
Returns
Type Description
ExplainedAllowPolicy.Builder
Overrides

getAllowAccessState()

public AllowAccessState getAllowAccessState()

Required. Indicates whether this policy provides the specified permission to the specified principal for the specified resource.

This field does not indicate whether the principal actually has the permission for the resource. There might be another policy that overrides this policy. To determine whether the principal actually has the permission, use the overall_access_state field in the TroubleshootIamPolicyResponse.

.google.cloud.policytroubleshooter.iam.v3.AllowAccessState allow_access_state = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
AllowAccessState

The allowAccessState.

getAllowAccessStateValue()

public int getAllowAccessStateValue()

Required. Indicates whether this policy provides the specified permission to the specified principal for the specified resource.

This field does not indicate whether the principal actually has the permission for the resource. There might be another policy that overrides this policy. To determine whether the principal actually has the permission, use the overall_access_state field in the TroubleshootIamPolicyResponse.

.google.cloud.policytroubleshooter.iam.v3.AllowAccessState allow_access_state = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
int

The enum numeric value on the wire for allowAccessState.

getBindingExplanations(int index)

public AllowBindingExplanation getBindingExplanations(int index)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameter
Name Description
index int
Returns
Type Description
AllowBindingExplanation

getBindingExplanationsBuilder(int index)

public AllowBindingExplanation.Builder getBindingExplanationsBuilder(int index)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameter
Name Description
index int
Returns
Type Description
AllowBindingExplanation.Builder

getBindingExplanationsBuilderList()

public List<AllowBindingExplanation.Builder> getBindingExplanationsBuilderList()

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Returns
Type Description
List<Builder>

getBindingExplanationsCount()

public int getBindingExplanationsCount()

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Returns
Type Description
int

getBindingExplanationsList()

public List<AllowBindingExplanation> getBindingExplanationsList()

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Returns
Type Description
List<AllowBindingExplanation>

getBindingExplanationsOrBuilder(int index)

public AllowBindingExplanationOrBuilder getBindingExplanationsOrBuilder(int index)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameter
Name Description
index int
Returns
Type Description
AllowBindingExplanationOrBuilder

getBindingExplanationsOrBuilderList()

public List<? extends AllowBindingExplanationOrBuilder> getBindingExplanationsOrBuilderList()

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Returns
Type Description
List<? extends com.google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanationOrBuilder>

getDefaultInstanceForType()

public ExplainedAllowPolicy getDefaultInstanceForType()
Returns
Type Description
ExplainedAllowPolicy

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getFullResourceName()

public String getFullResourceName()

The full resource name that identifies the resource. For example, //compute.googleapis.com/projects/my-project/zones/us-central1-a/instances/my-instance.

If the sender of the request does not have access to the policy, this field is omitted.

For examples of full resource names for Google Cloud services, see https://cloud.google.com/iam/help/troubleshooter/full-resource-names.

string full_resource_name = 2;

Returns
Type Description
String

The fullResourceName.

getFullResourceNameBytes()

public ByteString getFullResourceNameBytes()

The full resource name that identifies the resource. For example, //compute.googleapis.com/projects/my-project/zones/us-central1-a/instances/my-instance.

If the sender of the request does not have access to the policy, this field is omitted.

For examples of full resource names for Google Cloud services, see https://cloud.google.com/iam/help/troubleshooter/full-resource-names.

string full_resource_name = 2;

Returns
Type Description
ByteString

The bytes for fullResourceName.

getPolicy()

public Policy getPolicy()

The IAM allow policy attached to the resource.

If the sender of the request does not have access to the policy, this field is empty.

.google.iam.v1.Policy policy = 5;

Returns
Type Description
com.google.iam.v1.Policy

The policy.

getPolicyBuilder()

public Policy.Builder getPolicyBuilder()

The IAM allow policy attached to the resource.

If the sender of the request does not have access to the policy, this field is empty.

.google.iam.v1.Policy policy = 5;

Returns
Type Description
com.google.iam.v1.Policy.Builder

getPolicyOrBuilder()

public PolicyOrBuilder getPolicyOrBuilder()

The IAM allow policy attached to the resource.

If the sender of the request does not have access to the policy, this field is empty.

.google.iam.v1.Policy policy = 5;

Returns
Type Description
com.google.iam.v1.PolicyOrBuilder

getRelevance()

public HeuristicRelevance getRelevance()

The relevance of this policy to the overall access state in the TroubleshootIamPolicyResponse.

If the sender of the request does not have access to the policy, this field is omitted.

.google.cloud.policytroubleshooter.iam.v3.HeuristicRelevance relevance = 4;

Returns
Type Description
HeuristicRelevance

The relevance.

getRelevanceValue()

public int getRelevanceValue()

The relevance of this policy to the overall access state in the TroubleshootIamPolicyResponse.

If the sender of the request does not have access to the policy, this field is omitted.

.google.cloud.policytroubleshooter.iam.v3.HeuristicRelevance relevance = 4;

Returns
Type Description
int

The enum numeric value on the wire for relevance.

hasPolicy()

public boolean hasPolicy()

The IAM allow policy attached to the resource.

If the sender of the request does not have access to the policy, this field is empty.

.google.iam.v1.Policy policy = 5;

Returns
Type Description
boolean

Whether the policy field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(ExplainedAllowPolicy other)

public ExplainedAllowPolicy.Builder mergeFrom(ExplainedAllowPolicy other)
Parameter
Name Description
other ExplainedAllowPolicy
Returns
Type Description
ExplainedAllowPolicy.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public ExplainedAllowPolicy.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
ExplainedAllowPolicy.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public ExplainedAllowPolicy.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
ExplainedAllowPolicy.Builder
Overrides

mergePolicy(Policy value)

public ExplainedAllowPolicy.Builder mergePolicy(Policy value)

The IAM allow policy attached to the resource.

If the sender of the request does not have access to the policy, this field is empty.

.google.iam.v1.Policy policy = 5;

Parameter
Name Description
value com.google.iam.v1.Policy
Returns
Type Description
ExplainedAllowPolicy.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final ExplainedAllowPolicy.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
ExplainedAllowPolicy.Builder
Overrides

removeBindingExplanations(int index)

public ExplainedAllowPolicy.Builder removeBindingExplanations(int index)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameter
Name Description
index int
Returns
Type Description
ExplainedAllowPolicy.Builder

setAllowAccessState(AllowAccessState value)

public ExplainedAllowPolicy.Builder setAllowAccessState(AllowAccessState value)

Required. Indicates whether this policy provides the specified permission to the specified principal for the specified resource.

This field does not indicate whether the principal actually has the permission for the resource. There might be another policy that overrides this policy. To determine whether the principal actually has the permission, use the overall_access_state field in the TroubleshootIamPolicyResponse.

.google.cloud.policytroubleshooter.iam.v3.AllowAccessState allow_access_state = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value AllowAccessState

The allowAccessState to set.

Returns
Type Description
ExplainedAllowPolicy.Builder

This builder for chaining.

setAllowAccessStateValue(int value)

public ExplainedAllowPolicy.Builder setAllowAccessStateValue(int value)

Required. Indicates whether this policy provides the specified permission to the specified principal for the specified resource.

This field does not indicate whether the principal actually has the permission for the resource. There might be another policy that overrides this policy. To determine whether the principal actually has the permission, use the overall_access_state field in the TroubleshootIamPolicyResponse.

.google.cloud.policytroubleshooter.iam.v3.AllowAccessState allow_access_state = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value int

The enum numeric value on the wire for allowAccessState to set.

Returns
Type Description
ExplainedAllowPolicy.Builder

This builder for chaining.

setBindingExplanations(int index, AllowBindingExplanation value)

public ExplainedAllowPolicy.Builder setBindingExplanations(int index, AllowBindingExplanation value)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameters
Name Description
index int
value AllowBindingExplanation
Returns
Type Description
ExplainedAllowPolicy.Builder

setBindingExplanations(int index, AllowBindingExplanation.Builder builderForValue)

public ExplainedAllowPolicy.Builder setBindingExplanations(int index, AllowBindingExplanation.Builder builderForValue)

Details about how each role binding in the policy affects the principal's ability, or inability, to use the permission for the resource. The order of the role bindings matches the role binding order in the policy.

If the sender of the request does not have access to the policy, this field is omitted.

repeated .google.cloud.policytroubleshooter.iam.v3.AllowBindingExplanation binding_explanations = 3;

Parameters
Name Description
index int
builderForValue AllowBindingExplanation.Builder
Returns
Type Description
ExplainedAllowPolicy.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public ExplainedAllowPolicy.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
ExplainedAllowPolicy.Builder
Overrides

setFullResourceName(String value)

public ExplainedAllowPolicy.Builder setFullResourceName(String value)

The full resource name that identifies the resource. For example, //compute.googleapis.com/projects/my-project/zones/us-central1-a/instances/my-instance.

If the sender of the request does not have access to the policy, this field is omitted.

For examples of full resource names for Google Cloud services, see https://cloud.google.com/iam/help/troubleshooter/full-resource-names.

string full_resource_name = 2;

Parameter
Name Description
value String

The fullResourceName to set.

Returns
Type Description
ExplainedAllowPolicy.Builder

This builder for chaining.

setFullResourceNameBytes(ByteString value)

public ExplainedAllowPolicy.Builder setFullResourceNameBytes(ByteString value)

The full resource name that identifies the resource. For example, //compute.googleapis.com/projects/my-project/zones/us-central1-a/instances/my-instance.

If the sender of the request does not have access to the policy, this field is omitted.

For examples of full resource names for Google Cloud services, see https://cloud.google.com/iam/help/troubleshooter/full-resource-names.

string full_resource_name = 2;

Parameter
Name Description
value ByteString

The bytes for fullResourceName to set.

Returns
Type Description
ExplainedAllowPolicy.Builder

This builder for chaining.

setPolicy(Policy value)

public ExplainedAllowPolicy.Builder setPolicy(Policy value)

The IAM allow policy attached to the resource.

If the sender of the request does not have access to the policy, this field is empty.

.google.iam.v1.Policy policy = 5;

Parameter
Name Description
value com.google.iam.v1.Policy
Returns
Type Description
ExplainedAllowPolicy.Builder

setPolicy(Policy.Builder builderForValue)

public ExplainedAllowPolicy.Builder setPolicy(Policy.Builder builderForValue)

The IAM allow policy attached to the resource.

If the sender of the request does not have access to the policy, this field is empty.

.google.iam.v1.Policy policy = 5;

Parameter
Name Description
builderForValue com.google.iam.v1.Policy.Builder
Returns
Type Description
ExplainedAllowPolicy.Builder

setRelevance(HeuristicRelevance value)

public ExplainedAllowPolicy.Builder setRelevance(HeuristicRelevance value)

The relevance of this policy to the overall access state in the TroubleshootIamPolicyResponse.

If the sender of the request does not have access to the policy, this field is omitted.

.google.cloud.policytroubleshooter.iam.v3.HeuristicRelevance relevance = 4;

Parameter
Name Description
value HeuristicRelevance

The relevance to set.

Returns
Type Description
ExplainedAllowPolicy.Builder

This builder for chaining.

setRelevanceValue(int value)

public ExplainedAllowPolicy.Builder setRelevanceValue(int value)

The relevance of this policy to the overall access state in the TroubleshootIamPolicyResponse.

If the sender of the request does not have access to the policy, this field is omitted.

.google.cloud.policytroubleshooter.iam.v3.HeuristicRelevance relevance = 4;

Parameter
Name Description
value int

The enum numeric value on the wire for relevance to set.

Returns
Type Description
ExplainedAllowPolicy.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public ExplainedAllowPolicy.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
ExplainedAllowPolicy.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final ExplainedAllowPolicy.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
ExplainedAllowPolicy.Builder
Overrides