- * API Overview - * Manages Identity and Access Management (IAM) policies. - * Any implementation of an API that offers access control features - * implements the google.iam.v1.IAMPolicy interface. - * ## Data model - * Access control is applied when a principal (user or service account), takes - * some action on a resource exposed by a service. Resources, identified by - * URI-like names, are the unit of access control specification. Service - * implementations can choose the granularity of access control and the - * supported permissions for their resources. - * For example one database service may allow access control to be - * specified only at the Table level, whereas another might allow access control - * to also be specified at the Column level. - * ## Policy Structure - * See google.iam.v1.Policy - * This is intentionally not a CRUD style API because access control policies - * are created and deleted implicitly with the resources to which they are - * attached. - *- */ -@javax.annotation.Generated( - value = "by gRPC proto compiler", - comments = "Source: google/iam/v1/iam_policy.proto") -@io.grpc.stub.annotations.GrpcGenerated -public final class IAMPolicyGrpc { - - private IAMPolicyGrpc() {} - - public static final String SERVICE_NAME = "google.iam.v1.IAMPolicy"; - - // Static method descriptors that strictly reflect the proto. - private static volatile io.grpc.MethodDescriptor< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> - getSetIamPolicyMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "SetIamPolicy", - requestType = com.google.iam.v1.SetIamPolicyRequest.class, - responseType = com.google.iam.v1.Policy.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> - getSetIamPolicyMethod() { - io.grpc.MethodDescriptor
- * API Overview - * Manages Identity and Access Management (IAM) policies. - * Any implementation of an API that offers access control features - * implements the google.iam.v1.IAMPolicy interface. - * ## Data model - * Access control is applied when a principal (user or service account), takes - * some action on a resource exposed by a service. Resources, identified by - * URI-like names, are the unit of access control specification. Service - * implementations can choose the granularity of access control and the - * supported permissions for their resources. - * For example one database service may allow access control to be - * specified only at the Table level, whereas another might allow access control - * to also be specified at the Column level. - * ## Policy Structure - * See google.iam.v1.Policy - * This is intentionally not a CRUD style API because access control policies - * are created and deleted implicitly with the resources to which they are - * attached. - *- */ - public abstract static class IAMPolicyImplBase implements io.grpc.BindableService { - - /** - * - * - *
- * Sets the access control policy on the specified resource. Replaces any - * existing policy. - * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. - *- */ - public void setIamPolicy( - com.google.iam.v1.SetIamPolicyRequest request, - io.grpc.stub.StreamObserver
- * Gets the access control policy for a resource. - * Returns an empty policy if the resource exists and does not have a policy - * set. - *- */ - public void getIamPolicy( - com.google.iam.v1.GetIamPolicyRequest request, - io.grpc.stub.StreamObserver
- * Returns permissions that a caller has on the specified resource. - * If the resource does not exist, this will return an empty set of - * permissions, not a `NOT_FOUND` error. - * Note: This operation is designed to be used for building permission-aware - * UIs and command-line tools, not for authorization checking. This operation - * may "fail open" without warning. - *- */ - public void testIamPermissions( - com.google.iam.v1.TestIamPermissionsRequest request, - io.grpc.stub.StreamObserver
- * API Overview - * Manages Identity and Access Management (IAM) policies. - * Any implementation of an API that offers access control features - * implements the google.iam.v1.IAMPolicy interface. - * ## Data model - * Access control is applied when a principal (user or service account), takes - * some action on a resource exposed by a service. Resources, identified by - * URI-like names, are the unit of access control specification. Service - * implementations can choose the granularity of access control and the - * supported permissions for their resources. - * For example one database service may allow access control to be - * specified only at the Table level, whereas another might allow access control - * to also be specified at the Column level. - * ## Policy Structure - * See google.iam.v1.Policy - * This is intentionally not a CRUD style API because access control policies - * are created and deleted implicitly with the resources to which they are - * attached. - *- */ - public static final class IAMPolicyStub extends io.grpc.stub.AbstractAsyncStub
- * Sets the access control policy on the specified resource. Replaces any - * existing policy. - * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. - *- */ - public void setIamPolicy( - com.google.iam.v1.SetIamPolicyRequest request, - io.grpc.stub.StreamObserver
- * Gets the access control policy for a resource. - * Returns an empty policy if the resource exists and does not have a policy - * set. - *- */ - public void getIamPolicy( - com.google.iam.v1.GetIamPolicyRequest request, - io.grpc.stub.StreamObserver
- * Returns permissions that a caller has on the specified resource. - * If the resource does not exist, this will return an empty set of - * permissions, not a `NOT_FOUND` error. - * Note: This operation is designed to be used for building permission-aware - * UIs and command-line tools, not for authorization checking. This operation - * may "fail open" without warning. - *- */ - public void testIamPermissions( - com.google.iam.v1.TestIamPermissionsRequest request, - io.grpc.stub.StreamObserver
- * API Overview - * Manages Identity and Access Management (IAM) policies. - * Any implementation of an API that offers access control features - * implements the google.iam.v1.IAMPolicy interface. - * ## Data model - * Access control is applied when a principal (user or service account), takes - * some action on a resource exposed by a service. Resources, identified by - * URI-like names, are the unit of access control specification. Service - * implementations can choose the granularity of access control and the - * supported permissions for their resources. - * For example one database service may allow access control to be - * specified only at the Table level, whereas another might allow access control - * to also be specified at the Column level. - * ## Policy Structure - * See google.iam.v1.Policy - * This is intentionally not a CRUD style API because access control policies - * are created and deleted implicitly with the resources to which they are - * attached. - *- */ - public static final class IAMPolicyBlockingStub - extends io.grpc.stub.AbstractBlockingStub
- * Sets the access control policy on the specified resource. Replaces any - * existing policy. - * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. - *- */ - public com.google.iam.v1.Policy setIamPolicy(com.google.iam.v1.SetIamPolicyRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getSetIamPolicyMethod(), getCallOptions(), request); - } - - /** - * - * - *
- * Gets the access control policy for a resource. - * Returns an empty policy if the resource exists and does not have a policy - * set. - *- */ - public com.google.iam.v1.Policy getIamPolicy(com.google.iam.v1.GetIamPolicyRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetIamPolicyMethod(), getCallOptions(), request); - } - - /** - * - * - *
- * Returns permissions that a caller has on the specified resource. - * If the resource does not exist, this will return an empty set of - * permissions, not a `NOT_FOUND` error. - * Note: This operation is designed to be used for building permission-aware - * UIs and command-line tools, not for authorization checking. This operation - * may "fail open" without warning. - *- */ - public com.google.iam.v1.TestIamPermissionsResponse testIamPermissions( - com.google.iam.v1.TestIamPermissionsRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getTestIamPermissionsMethod(), getCallOptions(), request); - } - } - - /** - * - * - *
- * API Overview - * Manages Identity and Access Management (IAM) policies. - * Any implementation of an API that offers access control features - * implements the google.iam.v1.IAMPolicy interface. - * ## Data model - * Access control is applied when a principal (user or service account), takes - * some action on a resource exposed by a service. Resources, identified by - * URI-like names, are the unit of access control specification. Service - * implementations can choose the granularity of access control and the - * supported permissions for their resources. - * For example one database service may allow access control to be - * specified only at the Table level, whereas another might allow access control - * to also be specified at the Column level. - * ## Policy Structure - * See google.iam.v1.Policy - * This is intentionally not a CRUD style API because access control policies - * are created and deleted implicitly with the resources to which they are - * attached. - *- */ - public static final class IAMPolicyFutureStub - extends io.grpc.stub.AbstractFutureStub
- * Sets the access control policy on the specified resource. Replaces any - * existing policy. - * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. - *- */ - public com.google.common.util.concurrent.ListenableFuture
- * Gets the access control policy for a resource. - * Returns an empty policy if the resource exists and does not have a policy - * set. - *- */ - public com.google.common.util.concurrent.ListenableFuture
- * Returns permissions that a caller has on the specified resource. - * If the resource does not exist, this will return an empty set of - * permissions, not a `NOT_FOUND` error. - * Note: This operation is designed to be used for building permission-aware - * UIs and command-line tools, not for authorization checking. This operation - * may "fail open" without warning. - *- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.iam.v1.TestIamPermissionsResponse> - testIamPermissions(com.google.iam.v1.TestIamPermissionsRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getTestIamPermissionsMethod(), getCallOptions()), request); - } - } - - private static final int METHODID_SET_IAM_POLICY = 0; - private static final int METHODID_GET_IAM_POLICY = 1; - private static final int METHODID_TEST_IAM_PERMISSIONS = 2; - - private static final class MethodHandlers
- * An interface for managing Identity and Access Management (IAM) policies. - *- */ -@javax.annotation.Generated( - value = "by gRPC proto compiler", - comments = "Source: google/iam/v2/policy.proto") -@io.grpc.stub.annotations.GrpcGenerated -public final class PoliciesGrpc { - - private PoliciesGrpc() {} - - public static final String SERVICE_NAME = "google.iam.v2.Policies"; - - // Static method descriptors that strictly reflect the proto. - private static volatile io.grpc.MethodDescriptor< - com.google.iam.v2.ListPoliciesRequest, com.google.iam.v2.ListPoliciesResponse> - getListPoliciesMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ListPolicies", - requestType = com.google.iam.v2.ListPoliciesRequest.class, - responseType = com.google.iam.v2.ListPoliciesResponse.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.iam.v2.ListPoliciesRequest, com.google.iam.v2.ListPoliciesResponse> - getListPoliciesMethod() { - io.grpc.MethodDescriptor< - com.google.iam.v2.ListPoliciesRequest, com.google.iam.v2.ListPoliciesResponse> - getListPoliciesMethod; - if ((getListPoliciesMethod = PoliciesGrpc.getListPoliciesMethod) == null) { - synchronized (PoliciesGrpc.class) { - if ((getListPoliciesMethod = PoliciesGrpc.getListPoliciesMethod) == null) { - PoliciesGrpc.getListPoliciesMethod = - getListPoliciesMethod = - io.grpc.MethodDescriptor - .
- * An interface for managing Identity and Access Management (IAM) policies. - *- */ - public abstract static class PoliciesImplBase implements io.grpc.BindableService { - - /** - * - * - *
- * Retrieves the policies of the specified kind that are attached to a - * resource. - * The response lists only policy metadata. In particular, policy rules are - * omitted. - *- */ - public void listPolicies( - com.google.iam.v2.ListPoliciesRequest request, - io.grpc.stub.StreamObserver
- * Gets a policy. - *- */ - public void getPolicy( - com.google.iam.v2.GetPolicyRequest request, - io.grpc.stub.StreamObserver
- * Creates a policy. - *- */ - public void createPolicy( - com.google.iam.v2.CreatePolicyRequest request, - io.grpc.stub.StreamObserver
- * Updates the specified policy. - * You can update only the rules and the display name for the policy. - * To update a policy, you should use a read-modify-write loop: - * 1. Use [GetPolicy][google.iam.v2.Policies.GetPolicy] to read the current version of the policy. - * 2. Modify the policy as needed. - * 3. Use `UpdatePolicy` to write the updated policy. - * This pattern helps prevent conflicts between concurrent updates. - *- */ - public void updatePolicy( - com.google.iam.v2.UpdatePolicyRequest request, - io.grpc.stub.StreamObserver
- * Deletes a policy. This action is permanent. - *- */ - public void deletePolicy( - com.google.iam.v2.DeletePolicyRequest request, - io.grpc.stub.StreamObserver
- * An interface for managing Identity and Access Management (IAM) policies. - *- */ - public static final class PoliciesStub extends io.grpc.stub.AbstractAsyncStub
- * Retrieves the policies of the specified kind that are attached to a - * resource. - * The response lists only policy metadata. In particular, policy rules are - * omitted. - *- */ - public void listPolicies( - com.google.iam.v2.ListPoliciesRequest request, - io.grpc.stub.StreamObserver
- * Gets a policy. - *- */ - public void getPolicy( - com.google.iam.v2.GetPolicyRequest request, - io.grpc.stub.StreamObserver
- * Creates a policy. - *- */ - public void createPolicy( - com.google.iam.v2.CreatePolicyRequest request, - io.grpc.stub.StreamObserver
- * Updates the specified policy. - * You can update only the rules and the display name for the policy. - * To update a policy, you should use a read-modify-write loop: - * 1. Use [GetPolicy][google.iam.v2.Policies.GetPolicy] to read the current version of the policy. - * 2. Modify the policy as needed. - * 3. Use `UpdatePolicy` to write the updated policy. - * This pattern helps prevent conflicts between concurrent updates. - *- */ - public void updatePolicy( - com.google.iam.v2.UpdatePolicyRequest request, - io.grpc.stub.StreamObserver
- * Deletes a policy. This action is permanent. - *- */ - public void deletePolicy( - com.google.iam.v2.DeletePolicyRequest request, - io.grpc.stub.StreamObserver
- * An interface for managing Identity and Access Management (IAM) policies. - *- */ - public static final class PoliciesBlockingStub - extends io.grpc.stub.AbstractBlockingStub
- * Retrieves the policies of the specified kind that are attached to a - * resource. - * The response lists only policy metadata. In particular, policy rules are - * omitted. - *- */ - public com.google.iam.v2.ListPoliciesResponse listPolicies( - com.google.iam.v2.ListPoliciesRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListPoliciesMethod(), getCallOptions(), request); - } - - /** - * - * - *
- * Gets a policy. - *- */ - public com.google.iam.v2.Policy getPolicy(com.google.iam.v2.GetPolicyRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetPolicyMethod(), getCallOptions(), request); - } - - /** - * - * - *
- * Creates a policy. - *- */ - public com.google.longrunning.Operation createPolicy( - com.google.iam.v2.CreatePolicyRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getCreatePolicyMethod(), getCallOptions(), request); - } - - /** - * - * - *
- * Updates the specified policy. - * You can update only the rules and the display name for the policy. - * To update a policy, you should use a read-modify-write loop: - * 1. Use [GetPolicy][google.iam.v2.Policies.GetPolicy] to read the current version of the policy. - * 2. Modify the policy as needed. - * 3. Use `UpdatePolicy` to write the updated policy. - * This pattern helps prevent conflicts between concurrent updates. - *- */ - public com.google.longrunning.Operation updatePolicy( - com.google.iam.v2.UpdatePolicyRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getUpdatePolicyMethod(), getCallOptions(), request); - } - - /** - * - * - *
- * Deletes a policy. This action is permanent. - *- */ - public com.google.longrunning.Operation deletePolicy( - com.google.iam.v2.DeletePolicyRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getDeletePolicyMethod(), getCallOptions(), request); - } - } - - /** - * - * - *
- * An interface for managing Identity and Access Management (IAM) policies. - *- */ - public static final class PoliciesFutureStub - extends io.grpc.stub.AbstractFutureStub
- * Retrieves the policies of the specified kind that are attached to a - * resource. - * The response lists only policy metadata. In particular, policy rules are - * omitted. - *- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.iam.v2.ListPoliciesResponse> - listPolicies(com.google.iam.v2.ListPoliciesRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListPoliciesMethod(), getCallOptions()), request); - } - - /** - * - * - *
- * Gets a policy. - *- */ - public com.google.common.util.concurrent.ListenableFuture
- * Creates a policy. - *- */ - public com.google.common.util.concurrent.ListenableFuture
- * Updates the specified policy. - * You can update only the rules and the display name for the policy. - * To update a policy, you should use a read-modify-write loop: - * 1. Use [GetPolicy][google.iam.v2.Policies.GetPolicy] to read the current version of the policy. - * 2. Modify the policy as needed. - * 3. Use `UpdatePolicy` to write the updated policy. - * This pattern helps prevent conflicts between concurrent updates. - *- */ - public com.google.common.util.concurrent.ListenableFuture
- * Deletes a policy. This action is permanent. - *- */ - public com.google.common.util.concurrent.ListenableFuture
- * An interface for managing Identity and Access Management (IAM) policies. - *- */ -@javax.annotation.Generated( - value = "by gRPC proto compiler", - comments = "Source: google/iam/v2beta/policy.proto") -@io.grpc.stub.annotations.GrpcGenerated -public final class PoliciesGrpc { - - private PoliciesGrpc() {} - - public static final String SERVICE_NAME = "google.iam.v2beta.Policies"; - - // Static method descriptors that strictly reflect the proto. - private static volatile io.grpc.MethodDescriptor< - com.google.iam.v2beta.ListPoliciesRequest, com.google.iam.v2beta.ListPoliciesResponse> - getListPoliciesMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ListPolicies", - requestType = com.google.iam.v2beta.ListPoliciesRequest.class, - responseType = com.google.iam.v2beta.ListPoliciesResponse.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.iam.v2beta.ListPoliciesRequest, com.google.iam.v2beta.ListPoliciesResponse> - getListPoliciesMethod() { - io.grpc.MethodDescriptor< - com.google.iam.v2beta.ListPoliciesRequest, com.google.iam.v2beta.ListPoliciesResponse> - getListPoliciesMethod; - if ((getListPoliciesMethod = PoliciesGrpc.getListPoliciesMethod) == null) { - synchronized (PoliciesGrpc.class) { - if ((getListPoliciesMethod = PoliciesGrpc.getListPoliciesMethod) == null) { - PoliciesGrpc.getListPoliciesMethod = - getListPoliciesMethod = - io.grpc.MethodDescriptor - .
- * An interface for managing Identity and Access Management (IAM) policies. - *- */ - public abstract static class PoliciesImplBase implements io.grpc.BindableService { - - /** - * - * - *
- * Retrieves the policies of the specified kind that are attached to a - * resource. - * The response lists only policy metadata. In particular, policy rules are - * omitted. - *- */ - public void listPolicies( - com.google.iam.v2beta.ListPoliciesRequest request, - io.grpc.stub.StreamObserver
- * Gets a policy. - *- */ - public void getPolicy( - com.google.iam.v2beta.GetPolicyRequest request, - io.grpc.stub.StreamObserver
- * Creates a policy. - *- */ - public void createPolicy( - com.google.iam.v2beta.CreatePolicyRequest request, - io.grpc.stub.StreamObserver
- * Updates the specified policy. - * You can update only the rules and the display name for the policy. - * To update a policy, you should use a read-modify-write loop: - * 1. Use [GetPolicy][google.iam.v2beta.Policies.GetPolicy] to read the current version of the policy. - * 2. Modify the policy as needed. - * 3. Use `UpdatePolicy` to write the updated policy. - * This pattern helps prevent conflicts between concurrent updates. - *- */ - public void updatePolicy( - com.google.iam.v2beta.UpdatePolicyRequest request, - io.grpc.stub.StreamObserver
- * Deletes a policy. This action is permanent. - *- */ - public void deletePolicy( - com.google.iam.v2beta.DeletePolicyRequest request, - io.grpc.stub.StreamObserver
- * An interface for managing Identity and Access Management (IAM) policies. - *- */ - public static final class PoliciesStub extends io.grpc.stub.AbstractAsyncStub
- * Retrieves the policies of the specified kind that are attached to a - * resource. - * The response lists only policy metadata. In particular, policy rules are - * omitted. - *- */ - public void listPolicies( - com.google.iam.v2beta.ListPoliciesRequest request, - io.grpc.stub.StreamObserver
- * Gets a policy. - *- */ - public void getPolicy( - com.google.iam.v2beta.GetPolicyRequest request, - io.grpc.stub.StreamObserver
- * Creates a policy. - *- */ - public void createPolicy( - com.google.iam.v2beta.CreatePolicyRequest request, - io.grpc.stub.StreamObserver
- * Updates the specified policy. - * You can update only the rules and the display name for the policy. - * To update a policy, you should use a read-modify-write loop: - * 1. Use [GetPolicy][google.iam.v2beta.Policies.GetPolicy] to read the current version of the policy. - * 2. Modify the policy as needed. - * 3. Use `UpdatePolicy` to write the updated policy. - * This pattern helps prevent conflicts between concurrent updates. - *- */ - public void updatePolicy( - com.google.iam.v2beta.UpdatePolicyRequest request, - io.grpc.stub.StreamObserver
- * Deletes a policy. This action is permanent. - *- */ - public void deletePolicy( - com.google.iam.v2beta.DeletePolicyRequest request, - io.grpc.stub.StreamObserver
- * An interface for managing Identity and Access Management (IAM) policies. - *- */ - public static final class PoliciesBlockingStub - extends io.grpc.stub.AbstractBlockingStub
- * Retrieves the policies of the specified kind that are attached to a - * resource. - * The response lists only policy metadata. In particular, policy rules are - * omitted. - *- */ - public com.google.iam.v2beta.ListPoliciesResponse listPolicies( - com.google.iam.v2beta.ListPoliciesRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListPoliciesMethod(), getCallOptions(), request); - } - - /** - * - * - *
- * Gets a policy. - *- */ - public com.google.iam.v2beta.Policy getPolicy(com.google.iam.v2beta.GetPolicyRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetPolicyMethod(), getCallOptions(), request); - } - - /** - * - * - *
- * Creates a policy. - *- */ - public com.google.longrunning.Operation createPolicy( - com.google.iam.v2beta.CreatePolicyRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getCreatePolicyMethod(), getCallOptions(), request); - } - - /** - * - * - *
- * Updates the specified policy. - * You can update only the rules and the display name for the policy. - * To update a policy, you should use a read-modify-write loop: - * 1. Use [GetPolicy][google.iam.v2beta.Policies.GetPolicy] to read the current version of the policy. - * 2. Modify the policy as needed. - * 3. Use `UpdatePolicy` to write the updated policy. - * This pattern helps prevent conflicts between concurrent updates. - *- */ - public com.google.longrunning.Operation updatePolicy( - com.google.iam.v2beta.UpdatePolicyRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getUpdatePolicyMethod(), getCallOptions(), request); - } - - /** - * - * - *
- * Deletes a policy. This action is permanent. - *- */ - public com.google.longrunning.Operation deletePolicy( - com.google.iam.v2beta.DeletePolicyRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getDeletePolicyMethod(), getCallOptions(), request); - } - } - - /** - * - * - *
- * An interface for managing Identity and Access Management (IAM) policies. - *- */ - public static final class PoliciesFutureStub - extends io.grpc.stub.AbstractFutureStub
- * Retrieves the policies of the specified kind that are attached to a - * resource. - * The response lists only policy metadata. In particular, policy rules are - * omitted. - *- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.iam.v2beta.ListPoliciesResponse> - listPolicies(com.google.iam.v2beta.ListPoliciesRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListPoliciesMethod(), getCallOptions()), request); - } - - /** - * - * - *
- * Gets a policy. - *- */ - public com.google.common.util.concurrent.ListenableFuture
- * Creates a policy. - *- */ - public com.google.common.util.concurrent.ListenableFuture
- * Updates the specified policy. - * You can update only the rules and the display name for the policy. - * To update a policy, you should use a read-modify-write loop: - * 1. Use [GetPolicy][google.iam.v2beta.Policies.GetPolicy] to read the current version of the policy. - * 2. Modify the policy as needed. - * 3. Use `UpdatePolicy` to write the updated policy. - * This pattern helps prevent conflicts between concurrent updates. - *- */ - public com.google.common.util.concurrent.ListenableFuture
- * Deletes a policy. This action is permanent. - *- */ - public com.google.common.util.concurrent.ListenableFuture
- * Specifies the audit configuration for a service. - * The configuration determines which permission types are logged, and what - * identities, if any, are exempted from logging. - * An AuditConfig must have one or more AuditLogConfigs. - * If there are AuditConfigs for both `allServices` and a specific service, - * the union of the two AuditConfigs is used for that service: the log_types - * specified in each AuditConfig are enabled, and the exempted_members in each - * AuditLogConfig are exempted. - * Example Policy with multiple AuditConfigs: - * { - * "audit_configs": [ - * { - * "service": "allServices", - * "audit_log_configs": [ - * { - * "log_type": "DATA_READ", - * "exempted_members": [ - * "user:jose@example.com" - * ] - * }, - * { - * "log_type": "DATA_WRITE" - * }, - * { - * "log_type": "ADMIN_READ" - * } - * ] - * }, - * { - * "service": "sampleservice.googleapis.com", - * "audit_log_configs": [ - * { - * "log_type": "DATA_READ" - * }, - * { - * "log_type": "DATA_WRITE", - * "exempted_members": [ - * "user:aliya@example.com" - * ] - * } - * ] - * } - * ] - * } - * For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ - * logging. It also exempts jose@example.com from DATA_READ logging, and - * aliya@example.com from DATA_WRITE logging. - *- * - * Protobuf type {@code google.iam.v1.AuditConfig} - */ -public final class AuditConfig extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.AuditConfig) - AuditConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use AuditConfig.newBuilder() to construct. - private AuditConfig(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private AuditConfig() { - service_ = ""; - auditLogConfigs_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new AuditConfig(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_AuditConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.PolicyProto - .internal_static_google_iam_v1_AuditConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.AuditConfig.class, com.google.iam.v1.AuditConfig.Builder.class); - } - - public static final int SERVICE_FIELD_NUMBER = 1; - private volatile java.lang.Object service_; - /** - * - * - *
- * Specifies a service that will be enabled for audit logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - *- * - *
string service = 1;
- *
- * @return The service.
- */
- @java.lang.Override
- public java.lang.String getService() {
- java.lang.Object ref = service_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- service_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * Specifies a service that will be enabled for audit logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - *- * - *
string service = 1;
- *
- * @return The bytes for service.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getServiceBytes() {
- java.lang.Object ref = service_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- service_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- public static final int AUDIT_LOG_CONFIGS_FIELD_NUMBER = 3;
- private java.util.List- * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- @java.lang.Override
- public java.util.List- * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- @java.lang.Override
- public java.util.List extends com.google.iam.v1.AuditLogConfigOrBuilder>
- getAuditLogConfigsOrBuilderList() {
- return auditLogConfigs_;
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- @java.lang.Override
- public int getAuditLogConfigsCount() {
- return auditLogConfigs_.size();
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- @java.lang.Override
- public com.google.iam.v1.AuditLogConfig getAuditLogConfigs(int index) {
- return auditLogConfigs_.get(index);
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- @java.lang.Override
- public com.google.iam.v1.AuditLogConfigOrBuilder getAuditLogConfigsOrBuilder(int index) {
- return auditLogConfigs_.get(index);
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(service_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 1, service_);
- }
- for (int i = 0; i < auditLogConfigs_.size(); i++) {
- output.writeMessage(3, auditLogConfigs_.get(i));
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(service_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, service_);
- }
- for (int i = 0; i < auditLogConfigs_.size(); i++) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, auditLogConfigs_.get(i));
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.AuditConfig)) {
- return super.equals(obj);
- }
- com.google.iam.v1.AuditConfig other = (com.google.iam.v1.AuditConfig) obj;
-
- if (!getService().equals(other.getService())) return false;
- if (!getAuditLogConfigsList().equals(other.getAuditLogConfigsList())) return false;
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + SERVICE_FIELD_NUMBER;
- hash = (53 * hash) + getService().hashCode();
- if (getAuditLogConfigsCount() > 0) {
- hash = (37 * hash) + AUDIT_LOG_CONFIGS_FIELD_NUMBER;
- hash = (53 * hash) + getAuditLogConfigsList().hashCode();
- }
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.AuditConfig parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.AuditConfig parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditConfig parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.AuditConfig parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditConfig parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.AuditConfig parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditConfig parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.AuditConfig parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditConfig parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.AuditConfig parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditConfig parseFrom(com.google.protobuf.CodedInputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.AuditConfig parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.AuditConfig prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * Specifies the audit configuration for a service. - * The configuration determines which permission types are logged, and what - * identities, if any, are exempted from logging. - * An AuditConfig must have one or more AuditLogConfigs. - * If there are AuditConfigs for both `allServices` and a specific service, - * the union of the two AuditConfigs is used for that service: the log_types - * specified in each AuditConfig are enabled, and the exempted_members in each - * AuditLogConfig are exempted. - * Example Policy with multiple AuditConfigs: - * { - * "audit_configs": [ - * { - * "service": "allServices", - * "audit_log_configs": [ - * { - * "log_type": "DATA_READ", - * "exempted_members": [ - * "user:jose@example.com" - * ] - * }, - * { - * "log_type": "DATA_WRITE" - * }, - * { - * "log_type": "ADMIN_READ" - * } - * ] - * }, - * { - * "service": "sampleservice.googleapis.com", - * "audit_log_configs": [ - * { - * "log_type": "DATA_READ" - * }, - * { - * "log_type": "DATA_WRITE", - * "exempted_members": [ - * "user:aliya@example.com" - * ] - * } - * ] - * } - * ] - * } - * For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ - * logging. It also exempts jose@example.com from DATA_READ logging, and - * aliya@example.com from DATA_WRITE logging. - *- * - * Protobuf type {@code google.iam.v1.AuditConfig} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * Specifies a service that will be enabled for audit logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - *- * - *
string service = 1;
- *
- * @return The service.
- */
- public java.lang.String getService() {
- java.lang.Object ref = service_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- service_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * Specifies a service that will be enabled for audit logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - *- * - *
string service = 1;
- *
- * @return The bytes for service.
- */
- public com.google.protobuf.ByteString getServiceBytes() {
- java.lang.Object ref = service_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- service_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * Specifies a service that will be enabled for audit logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - *- * - *
string service = 1;
- *
- * @param value The service to set.
- * @return This builder for chaining.
- */
- public Builder setService(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- service_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies a service that will be enabled for audit logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - *- * - *
string service = 1;
- *
- * @return This builder for chaining.
- */
- public Builder clearService() {
-
- service_ = getDefaultInstance().getService();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies a service that will be enabled for audit logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - *- * - *
string service = 1;
- *
- * @param value The bytes for service to set.
- * @return This builder for chaining.
- */
- public Builder setServiceBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- service_ = value;
- onChanged();
- return this;
- }
-
- private java.util.List- * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public java.util.List- * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public int getAuditLogConfigsCount() {
- if (auditLogConfigsBuilder_ == null) {
- return auditLogConfigs_.size();
- } else {
- return auditLogConfigsBuilder_.getCount();
- }
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public com.google.iam.v1.AuditLogConfig getAuditLogConfigs(int index) {
- if (auditLogConfigsBuilder_ == null) {
- return auditLogConfigs_.get(index);
- } else {
- return auditLogConfigsBuilder_.getMessage(index);
- }
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public Builder setAuditLogConfigs(int index, com.google.iam.v1.AuditLogConfig value) {
- if (auditLogConfigsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAuditLogConfigsIsMutable();
- auditLogConfigs_.set(index, value);
- onChanged();
- } else {
- auditLogConfigsBuilder_.setMessage(index, value);
- }
- return this;
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public Builder setAuditLogConfigs(
- int index, com.google.iam.v1.AuditLogConfig.Builder builderForValue) {
- if (auditLogConfigsBuilder_ == null) {
- ensureAuditLogConfigsIsMutable();
- auditLogConfigs_.set(index, builderForValue.build());
- onChanged();
- } else {
- auditLogConfigsBuilder_.setMessage(index, builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public Builder addAuditLogConfigs(com.google.iam.v1.AuditLogConfig value) {
- if (auditLogConfigsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAuditLogConfigsIsMutable();
- auditLogConfigs_.add(value);
- onChanged();
- } else {
- auditLogConfigsBuilder_.addMessage(value);
- }
- return this;
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public Builder addAuditLogConfigs(int index, com.google.iam.v1.AuditLogConfig value) {
- if (auditLogConfigsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAuditLogConfigsIsMutable();
- auditLogConfigs_.add(index, value);
- onChanged();
- } else {
- auditLogConfigsBuilder_.addMessage(index, value);
- }
- return this;
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public Builder addAuditLogConfigs(com.google.iam.v1.AuditLogConfig.Builder builderForValue) {
- if (auditLogConfigsBuilder_ == null) {
- ensureAuditLogConfigsIsMutable();
- auditLogConfigs_.add(builderForValue.build());
- onChanged();
- } else {
- auditLogConfigsBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public Builder addAuditLogConfigs(
- int index, com.google.iam.v1.AuditLogConfig.Builder builderForValue) {
- if (auditLogConfigsBuilder_ == null) {
- ensureAuditLogConfigsIsMutable();
- auditLogConfigs_.add(index, builderForValue.build());
- onChanged();
- } else {
- auditLogConfigsBuilder_.addMessage(index, builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public Builder addAllAuditLogConfigs(
- java.lang.Iterable extends com.google.iam.v1.AuditLogConfig> values) {
- if (auditLogConfigsBuilder_ == null) {
- ensureAuditLogConfigsIsMutable();
- com.google.protobuf.AbstractMessageLite.Builder.addAll(values, auditLogConfigs_);
- onChanged();
- } else {
- auditLogConfigsBuilder_.addAllMessages(values);
- }
- return this;
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public Builder clearAuditLogConfigs() {
- if (auditLogConfigsBuilder_ == null) {
- auditLogConfigs_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000001);
- onChanged();
- } else {
- auditLogConfigsBuilder_.clear();
- }
- return this;
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public Builder removeAuditLogConfigs(int index) {
- if (auditLogConfigsBuilder_ == null) {
- ensureAuditLogConfigsIsMutable();
- auditLogConfigs_.remove(index);
- onChanged();
- } else {
- auditLogConfigsBuilder_.remove(index);
- }
- return this;
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public com.google.iam.v1.AuditLogConfig.Builder getAuditLogConfigsBuilder(int index) {
- return getAuditLogConfigsFieldBuilder().getBuilder(index);
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public com.google.iam.v1.AuditLogConfigOrBuilder getAuditLogConfigsOrBuilder(int index) {
- if (auditLogConfigsBuilder_ == null) {
- return auditLogConfigs_.get(index);
- } else {
- return auditLogConfigsBuilder_.getMessageOrBuilder(index);
- }
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public java.util.List extends com.google.iam.v1.AuditLogConfigOrBuilder>
- getAuditLogConfigsOrBuilderList() {
- if (auditLogConfigsBuilder_ != null) {
- return auditLogConfigsBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(auditLogConfigs_);
- }
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public com.google.iam.v1.AuditLogConfig.Builder addAuditLogConfigsBuilder() {
- return getAuditLogConfigsFieldBuilder()
- .addBuilder(com.google.iam.v1.AuditLogConfig.getDefaultInstance());
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public com.google.iam.v1.AuditLogConfig.Builder addAuditLogConfigsBuilder(int index) {
- return getAuditLogConfigsFieldBuilder()
- .addBuilder(index, com.google.iam.v1.AuditLogConfig.getDefaultInstance());
- }
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- public java.util.List- * One delta entry for AuditConfig. Each individual change (only one - * exempted_member in each entry) to a AuditConfig will be a separate entry. - *- * - * Protobuf type {@code google.iam.v1.AuditConfigDelta} - */ -public final class AuditConfigDelta extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.AuditConfigDelta) - AuditConfigDeltaOrBuilder { - private static final long serialVersionUID = 0L; - // Use AuditConfigDelta.newBuilder() to construct. - private AuditConfigDelta(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private AuditConfigDelta() { - action_ = 0; - service_ = ""; - exemptedMember_ = ""; - logType_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new AuditConfigDelta(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_AuditConfigDelta_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.PolicyProto - .internal_static_google_iam_v1_AuditConfigDelta_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.AuditConfigDelta.class, - com.google.iam.v1.AuditConfigDelta.Builder.class); - } - - /** - * - * - *
- * The type of action performed on an audit configuration in a policy. - *- * - * Protobuf enum {@code google.iam.v1.AuditConfigDelta.Action} - */ - public enum Action implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
- * Unspecified. - *- * - *
ACTION_UNSPECIFIED = 0;
- */
- ACTION_UNSPECIFIED(0),
- /**
- *
- *
- * - * Addition of an audit configuration. - *- * - *
ADD = 1;
- */
- ADD(1),
- /**
- *
- *
- * - * Removal of an audit configuration. - *- * - *
REMOVE = 2;
- */
- REMOVE(2),
- UNRECOGNIZED(-1),
- ;
-
- /**
- *
- *
- * - * Unspecified. - *- * - *
ACTION_UNSPECIFIED = 0;
- */
- public static final int ACTION_UNSPECIFIED_VALUE = 0;
- /**
- *
- *
- * - * Addition of an audit configuration. - *- * - *
ADD = 1;
- */
- public static final int ADD_VALUE = 1;
- /**
- *
- *
- * - * Removal of an audit configuration. - *- * - *
REMOVE = 2;
- */
- public static final int REMOVE_VALUE = 2;
-
- public final int getNumber() {
- if (this == UNRECOGNIZED) {
- throw new java.lang.IllegalArgumentException(
- "Can't get the number of an unknown enum value.");
- }
- return value;
- }
-
- /**
- * @param value The numeric wire value of the corresponding enum entry.
- * @return The enum associated with the given numeric wire value.
- * @deprecated Use {@link #forNumber(int)} instead.
- */
- @java.lang.Deprecated
- public static Action valueOf(int value) {
- return forNumber(value);
- }
-
- /**
- * @param value The numeric wire value of the corresponding enum entry.
- * @return The enum associated with the given numeric wire value.
- */
- public static Action forNumber(int value) {
- switch (value) {
- case 0:
- return ACTION_UNSPECIFIED;
- case 1:
- return ADD;
- case 2:
- return REMOVE;
- default:
- return null;
- }
- }
-
- public static com.google.protobuf.Internal.EnumLiteMap- * The action that was performed on an audit configuration in a policy. - * Required - *- * - *
.google.iam.v1.AuditConfigDelta.Action action = 1;
- *
- * @return The enum numeric value on the wire for action.
- */
- @java.lang.Override
- public int getActionValue() {
- return action_;
- }
- /**
- *
- *
- * - * The action that was performed on an audit configuration in a policy. - * Required - *- * - *
.google.iam.v1.AuditConfigDelta.Action action = 1;
- *
- * @return The action.
- */
- @java.lang.Override
- public com.google.iam.v1.AuditConfigDelta.Action getAction() {
- @SuppressWarnings("deprecation")
- com.google.iam.v1.AuditConfigDelta.Action result =
- com.google.iam.v1.AuditConfigDelta.Action.valueOf(action_);
- return result == null ? com.google.iam.v1.AuditConfigDelta.Action.UNRECOGNIZED : result;
- }
-
- public static final int SERVICE_FIELD_NUMBER = 2;
- private volatile java.lang.Object service_;
- /**
- *
- *
- * - * Specifies a service that was configured for Cloud Audit Logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - * Required - *- * - *
string service = 2;
- *
- * @return The service.
- */
- @java.lang.Override
- public java.lang.String getService() {
- java.lang.Object ref = service_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- service_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * Specifies a service that was configured for Cloud Audit Logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - * Required - *- * - *
string service = 2;
- *
- * @return The bytes for service.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getServiceBytes() {
- java.lang.Object ref = service_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- service_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- public static final int EXEMPTED_MEMBER_FIELD_NUMBER = 3;
- private volatile java.lang.Object exemptedMember_;
- /**
- *
- *
- * - * A single identity that is exempted from "data access" audit - * logging for the `service` specified above. - * Follows the same format of Binding.members. - *- * - *
string exempted_member = 3;
- *
- * @return The exemptedMember.
- */
- @java.lang.Override
- public java.lang.String getExemptedMember() {
- java.lang.Object ref = exemptedMember_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- exemptedMember_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * A single identity that is exempted from "data access" audit - * logging for the `service` specified above. - * Follows the same format of Binding.members. - *- * - *
string exempted_member = 3;
- *
- * @return The bytes for exemptedMember.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getExemptedMemberBytes() {
- java.lang.Object ref = exemptedMember_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- exemptedMember_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- public static final int LOG_TYPE_FIELD_NUMBER = 4;
- private volatile java.lang.Object logType_;
- /**
- *
- *
- * - * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always - * enabled, and cannot be configured. - * Required - *- * - *
string log_type = 4;
- *
- * @return The logType.
- */
- @java.lang.Override
- public java.lang.String getLogType() {
- java.lang.Object ref = logType_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- logType_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always - * enabled, and cannot be configured. - * Required - *- * - *
string log_type = 4;
- *
- * @return The bytes for logType.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getLogTypeBytes() {
- java.lang.Object ref = logType_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- logType_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (action_ != com.google.iam.v1.AuditConfigDelta.Action.ACTION_UNSPECIFIED.getNumber()) {
- output.writeEnum(1, action_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(service_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 2, service_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(exemptedMember_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 3, exemptedMember_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(logType_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 4, logType_);
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (action_ != com.google.iam.v1.AuditConfigDelta.Action.ACTION_UNSPECIFIED.getNumber()) {
- size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, action_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(service_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, service_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(exemptedMember_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, exemptedMember_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(logType_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, logType_);
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.AuditConfigDelta)) {
- return super.equals(obj);
- }
- com.google.iam.v1.AuditConfigDelta other = (com.google.iam.v1.AuditConfigDelta) obj;
-
- if (action_ != other.action_) return false;
- if (!getService().equals(other.getService())) return false;
- if (!getExemptedMember().equals(other.getExemptedMember())) return false;
- if (!getLogType().equals(other.getLogType())) return false;
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + ACTION_FIELD_NUMBER;
- hash = (53 * hash) + action_;
- hash = (37 * hash) + SERVICE_FIELD_NUMBER;
- hash = (53 * hash) + getService().hashCode();
- hash = (37 * hash) + EXEMPTED_MEMBER_FIELD_NUMBER;
- hash = (53 * hash) + getExemptedMember().hashCode();
- hash = (37 * hash) + LOG_TYPE_FIELD_NUMBER;
- hash = (53 * hash) + getLogType().hashCode();
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseFrom(
- com.google.protobuf.CodedInputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.AuditConfigDelta parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.AuditConfigDelta prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * One delta entry for AuditConfig. Each individual change (only one - * exempted_member in each entry) to a AuditConfig will be a separate entry. - *- * - * Protobuf type {@code google.iam.v1.AuditConfigDelta} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * The action that was performed on an audit configuration in a policy. - * Required - *- * - *
.google.iam.v1.AuditConfigDelta.Action action = 1;
- *
- * @return The enum numeric value on the wire for action.
- */
- @java.lang.Override
- public int getActionValue() {
- return action_;
- }
- /**
- *
- *
- * - * The action that was performed on an audit configuration in a policy. - * Required - *- * - *
.google.iam.v1.AuditConfigDelta.Action action = 1;
- *
- * @param value The enum numeric value on the wire for action to set.
- * @return This builder for chaining.
- */
- public Builder setActionValue(int value) {
-
- action_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The action that was performed on an audit configuration in a policy. - * Required - *- * - *
.google.iam.v1.AuditConfigDelta.Action action = 1;
- *
- * @return The action.
- */
- @java.lang.Override
- public com.google.iam.v1.AuditConfigDelta.Action getAction() {
- @SuppressWarnings("deprecation")
- com.google.iam.v1.AuditConfigDelta.Action result =
- com.google.iam.v1.AuditConfigDelta.Action.valueOf(action_);
- return result == null ? com.google.iam.v1.AuditConfigDelta.Action.UNRECOGNIZED : result;
- }
- /**
- *
- *
- * - * The action that was performed on an audit configuration in a policy. - * Required - *- * - *
.google.iam.v1.AuditConfigDelta.Action action = 1;
- *
- * @param value The action to set.
- * @return This builder for chaining.
- */
- public Builder setAction(com.google.iam.v1.AuditConfigDelta.Action value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- action_ = value.getNumber();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The action that was performed on an audit configuration in a policy. - * Required - *- * - *
.google.iam.v1.AuditConfigDelta.Action action = 1;
- *
- * @return This builder for chaining.
- */
- public Builder clearAction() {
-
- action_ = 0;
- onChanged();
- return this;
- }
-
- private java.lang.Object service_ = "";
- /**
- *
- *
- * - * Specifies a service that was configured for Cloud Audit Logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - * Required - *- * - *
string service = 2;
- *
- * @return The service.
- */
- public java.lang.String getService() {
- java.lang.Object ref = service_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- service_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * Specifies a service that was configured for Cloud Audit Logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - * Required - *- * - *
string service = 2;
- *
- * @return The bytes for service.
- */
- public com.google.protobuf.ByteString getServiceBytes() {
- java.lang.Object ref = service_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- service_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * Specifies a service that was configured for Cloud Audit Logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - * Required - *- * - *
string service = 2;
- *
- * @param value The service to set.
- * @return This builder for chaining.
- */
- public Builder setService(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- service_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies a service that was configured for Cloud Audit Logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - * Required - *- * - *
string service = 2;
- *
- * @return This builder for chaining.
- */
- public Builder clearService() {
-
- service_ = getDefaultInstance().getService();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies a service that was configured for Cloud Audit Logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - * Required - *- * - *
string service = 2;
- *
- * @param value The bytes for service to set.
- * @return This builder for chaining.
- */
- public Builder setServiceBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- service_ = value;
- onChanged();
- return this;
- }
-
- private java.lang.Object exemptedMember_ = "";
- /**
- *
- *
- * - * A single identity that is exempted from "data access" audit - * logging for the `service` specified above. - * Follows the same format of Binding.members. - *- * - *
string exempted_member = 3;
- *
- * @return The exemptedMember.
- */
- public java.lang.String getExemptedMember() {
- java.lang.Object ref = exemptedMember_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- exemptedMember_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * A single identity that is exempted from "data access" audit - * logging for the `service` specified above. - * Follows the same format of Binding.members. - *- * - *
string exempted_member = 3;
- *
- * @return The bytes for exemptedMember.
- */
- public com.google.protobuf.ByteString getExemptedMemberBytes() {
- java.lang.Object ref = exemptedMember_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- exemptedMember_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * A single identity that is exempted from "data access" audit - * logging for the `service` specified above. - * Follows the same format of Binding.members. - *- * - *
string exempted_member = 3;
- *
- * @param value The exemptedMember to set.
- * @return This builder for chaining.
- */
- public Builder setExemptedMember(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- exemptedMember_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * A single identity that is exempted from "data access" audit - * logging for the `service` specified above. - * Follows the same format of Binding.members. - *- * - *
string exempted_member = 3;
- *
- * @return This builder for chaining.
- */
- public Builder clearExemptedMember() {
-
- exemptedMember_ = getDefaultInstance().getExemptedMember();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * A single identity that is exempted from "data access" audit - * logging for the `service` specified above. - * Follows the same format of Binding.members. - *- * - *
string exempted_member = 3;
- *
- * @param value The bytes for exemptedMember to set.
- * @return This builder for chaining.
- */
- public Builder setExemptedMemberBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- exemptedMember_ = value;
- onChanged();
- return this;
- }
-
- private java.lang.Object logType_ = "";
- /**
- *
- *
- * - * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always - * enabled, and cannot be configured. - * Required - *- * - *
string log_type = 4;
- *
- * @return The logType.
- */
- public java.lang.String getLogType() {
- java.lang.Object ref = logType_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- logType_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always - * enabled, and cannot be configured. - * Required - *- * - *
string log_type = 4;
- *
- * @return The bytes for logType.
- */
- public com.google.protobuf.ByteString getLogTypeBytes() {
- java.lang.Object ref = logType_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- logType_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always - * enabled, and cannot be configured. - * Required - *- * - *
string log_type = 4;
- *
- * @param value The logType to set.
- * @return This builder for chaining.
- */
- public Builder setLogType(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- logType_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always - * enabled, and cannot be configured. - * Required - *- * - *
string log_type = 4;
- *
- * @return This builder for chaining.
- */
- public Builder clearLogType() {
-
- logType_ = getDefaultInstance().getLogType();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always - * enabled, and cannot be configured. - * Required - *- * - *
string log_type = 4;
- *
- * @param value The bytes for logType to set.
- * @return This builder for chaining.
- */
- public Builder setLogTypeBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- logType_ = value;
- onChanged();
- return this;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v1.AuditConfigDelta)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v1.AuditConfigDelta)
- private static final com.google.iam.v1.AuditConfigDelta DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v1.AuditConfigDelta();
- }
-
- public static com.google.iam.v1.AuditConfigDelta getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * The action that was performed on an audit configuration in a policy. - * Required - *- * - *
.google.iam.v1.AuditConfigDelta.Action action = 1;
- *
- * @return The enum numeric value on the wire for action.
- */
- int getActionValue();
- /**
- *
- *
- * - * The action that was performed on an audit configuration in a policy. - * Required - *- * - *
.google.iam.v1.AuditConfigDelta.Action action = 1;
- *
- * @return The action.
- */
- com.google.iam.v1.AuditConfigDelta.Action getAction();
-
- /**
- *
- *
- * - * Specifies a service that was configured for Cloud Audit Logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - * Required - *- * - *
string service = 2;
- *
- * @return The service.
- */
- java.lang.String getService();
- /**
- *
- *
- * - * Specifies a service that was configured for Cloud Audit Logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - * Required - *- * - *
string service = 2;
- *
- * @return The bytes for service.
- */
- com.google.protobuf.ByteString getServiceBytes();
-
- /**
- *
- *
- * - * A single identity that is exempted from "data access" audit - * logging for the `service` specified above. - * Follows the same format of Binding.members. - *- * - *
string exempted_member = 3;
- *
- * @return The exemptedMember.
- */
- java.lang.String getExemptedMember();
- /**
- *
- *
- * - * A single identity that is exempted from "data access" audit - * logging for the `service` specified above. - * Follows the same format of Binding.members. - *- * - *
string exempted_member = 3;
- *
- * @return The bytes for exemptedMember.
- */
- com.google.protobuf.ByteString getExemptedMemberBytes();
-
- /**
- *
- *
- * - * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always - * enabled, and cannot be configured. - * Required - *- * - *
string log_type = 4;
- *
- * @return The logType.
- */
- java.lang.String getLogType();
- /**
- *
- *
- * - * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always - * enabled, and cannot be configured. - * Required - *- * - *
string log_type = 4;
- *
- * @return The bytes for logType.
- */
- com.google.protobuf.ByteString getLogTypeBytes();
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditConfigOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditConfigOrBuilder.java
deleted file mode 100644
index 06911aaf..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditConfigOrBuilder.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/policy.proto
-
-package com.google.iam.v1;
-
-public interface AuditConfigOrBuilder
- extends
- // @@protoc_insertion_point(interface_extends:google.iam.v1.AuditConfig)
- com.google.protobuf.MessageOrBuilder {
-
- /**
- *
- *
- * - * Specifies a service that will be enabled for audit logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - *- * - *
string service = 1;
- *
- * @return The service.
- */
- java.lang.String getService();
- /**
- *
- *
- * - * Specifies a service that will be enabled for audit logging. - * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - * `allServices` is a special value that covers all services. - *- * - *
string service = 1;
- *
- * @return The bytes for service.
- */
- com.google.protobuf.ByteString getServiceBytes();
-
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- java.util.List- * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- com.google.iam.v1.AuditLogConfig getAuditLogConfigs(int index);
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- int getAuditLogConfigsCount();
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- java.util.List extends com.google.iam.v1.AuditLogConfigOrBuilder>
- getAuditLogConfigsOrBuilderList();
- /**
- *
- *
- * - * The configuration for logging of each type of permission. - *- * - *
repeated .google.iam.v1.AuditLogConfig audit_log_configs = 3;
- */
- com.google.iam.v1.AuditLogConfigOrBuilder getAuditLogConfigsOrBuilder(int index);
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditLogConfig.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditLogConfig.java
deleted file mode 100644
index 645f2c04..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditLogConfig.java
+++ /dev/null
@@ -1,1089 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/policy.proto
-
-package com.google.iam.v1;
-
-/**
- *
- *
- * - * Provides the configuration for logging a type of permissions. - * Example: - * { - * "audit_log_configs": [ - * { - * "log_type": "DATA_READ", - * "exempted_members": [ - * "user:jose@example.com" - * ] - * }, - * { - * "log_type": "DATA_WRITE" - * } - * ] - * } - * This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting - * jose@example.com from DATA_READ logging. - *- * - * Protobuf type {@code google.iam.v1.AuditLogConfig} - */ -public final class AuditLogConfig extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.AuditLogConfig) - AuditLogConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use AuditLogConfig.newBuilder() to construct. - private AuditLogConfig(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private AuditLogConfig() { - logType_ = 0; - exemptedMembers_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new AuditLogConfig(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_AuditLogConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.PolicyProto - .internal_static_google_iam_v1_AuditLogConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.AuditLogConfig.class, com.google.iam.v1.AuditLogConfig.Builder.class); - } - - /** - * - * - *
- * The list of valid permission types for which logging can be configured. - * Admin writes are always logged, and are not configurable. - *- * - * Protobuf enum {@code google.iam.v1.AuditLogConfig.LogType} - */ - public enum LogType implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
- * Default case. Should never be this. - *- * - *
LOG_TYPE_UNSPECIFIED = 0;
- */
- LOG_TYPE_UNSPECIFIED(0),
- /**
- *
- *
- * - * Admin reads. Example: CloudIAM getIamPolicy - *- * - *
ADMIN_READ = 1;
- */
- ADMIN_READ(1),
- /**
- *
- *
- * - * Data writes. Example: CloudSQL Users create - *- * - *
DATA_WRITE = 2;
- */
- DATA_WRITE(2),
- /**
- *
- *
- * - * Data reads. Example: CloudSQL Users list - *- * - *
DATA_READ = 3;
- */
- DATA_READ(3),
- UNRECOGNIZED(-1),
- ;
-
- /**
- *
- *
- * - * Default case. Should never be this. - *- * - *
LOG_TYPE_UNSPECIFIED = 0;
- */
- public static final int LOG_TYPE_UNSPECIFIED_VALUE = 0;
- /**
- *
- *
- * - * Admin reads. Example: CloudIAM getIamPolicy - *- * - *
ADMIN_READ = 1;
- */
- public static final int ADMIN_READ_VALUE = 1;
- /**
- *
- *
- * - * Data writes. Example: CloudSQL Users create - *- * - *
DATA_WRITE = 2;
- */
- public static final int DATA_WRITE_VALUE = 2;
- /**
- *
- *
- * - * Data reads. Example: CloudSQL Users list - *- * - *
DATA_READ = 3;
- */
- public static final int DATA_READ_VALUE = 3;
-
- public final int getNumber() {
- if (this == UNRECOGNIZED) {
- throw new java.lang.IllegalArgumentException(
- "Can't get the number of an unknown enum value.");
- }
- return value;
- }
-
- /**
- * @param value The numeric wire value of the corresponding enum entry.
- * @return The enum associated with the given numeric wire value.
- * @deprecated Use {@link #forNumber(int)} instead.
- */
- @java.lang.Deprecated
- public static LogType valueOf(int value) {
- return forNumber(value);
- }
-
- /**
- * @param value The numeric wire value of the corresponding enum entry.
- * @return The enum associated with the given numeric wire value.
- */
- public static LogType forNumber(int value) {
- switch (value) {
- case 0:
- return LOG_TYPE_UNSPECIFIED;
- case 1:
- return ADMIN_READ;
- case 2:
- return DATA_WRITE;
- case 3:
- return DATA_READ;
- default:
- return null;
- }
- }
-
- public static com.google.protobuf.Internal.EnumLiteMap- * The log type that this config enables. - *- * - *
.google.iam.v1.AuditLogConfig.LogType log_type = 1;
- *
- * @return The enum numeric value on the wire for logType.
- */
- @java.lang.Override
- public int getLogTypeValue() {
- return logType_;
- }
- /**
- *
- *
- * - * The log type that this config enables. - *- * - *
.google.iam.v1.AuditLogConfig.LogType log_type = 1;
- *
- * @return The logType.
- */
- @java.lang.Override
- public com.google.iam.v1.AuditLogConfig.LogType getLogType() {
- @SuppressWarnings("deprecation")
- com.google.iam.v1.AuditLogConfig.LogType result =
- com.google.iam.v1.AuditLogConfig.LogType.valueOf(logType_);
- return result == null ? com.google.iam.v1.AuditLogConfig.LogType.UNRECOGNIZED : result;
- }
-
- public static final int EXEMPTED_MEMBERS_FIELD_NUMBER = 2;
- private com.google.protobuf.LazyStringList exemptedMembers_;
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @return A list containing the exemptedMembers.
- */
- public com.google.protobuf.ProtocolStringList getExemptedMembersList() {
- return exemptedMembers_;
- }
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @return The count of exemptedMembers.
- */
- public int getExemptedMembersCount() {
- return exemptedMembers_.size();
- }
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @param index The index of the element to return.
- * @return The exemptedMembers at the given index.
- */
- public java.lang.String getExemptedMembers(int index) {
- return exemptedMembers_.get(index);
- }
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @param index The index of the value to return.
- * @return The bytes of the exemptedMembers at the given index.
- */
- public com.google.protobuf.ByteString getExemptedMembersBytes(int index) {
- return exemptedMembers_.getByteString(index);
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (logType_ != com.google.iam.v1.AuditLogConfig.LogType.LOG_TYPE_UNSPECIFIED.getNumber()) {
- output.writeEnum(1, logType_);
- }
- for (int i = 0; i < exemptedMembers_.size(); i++) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 2, exemptedMembers_.getRaw(i));
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (logType_ != com.google.iam.v1.AuditLogConfig.LogType.LOG_TYPE_UNSPECIFIED.getNumber()) {
- size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, logType_);
- }
- {
- int dataSize = 0;
- for (int i = 0; i < exemptedMembers_.size(); i++) {
- dataSize += computeStringSizeNoTag(exemptedMembers_.getRaw(i));
- }
- size += dataSize;
- size += 1 * getExemptedMembersList().size();
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.AuditLogConfig)) {
- return super.equals(obj);
- }
- com.google.iam.v1.AuditLogConfig other = (com.google.iam.v1.AuditLogConfig) obj;
-
- if (logType_ != other.logType_) return false;
- if (!getExemptedMembersList().equals(other.getExemptedMembersList())) return false;
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + LOG_TYPE_FIELD_NUMBER;
- hash = (53 * hash) + logType_;
- if (getExemptedMembersCount() > 0) {
- hash = (37 * hash) + EXEMPTED_MEMBERS_FIELD_NUMBER;
- hash = (53 * hash) + getExemptedMembersList().hashCode();
- }
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.AuditLogConfig parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.AuditLogConfig parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditLogConfig parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.AuditLogConfig parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditLogConfig parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.AuditLogConfig parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditLogConfig parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.AuditLogConfig parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditLogConfig parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.AuditLogConfig parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.AuditLogConfig parseFrom(
- com.google.protobuf.CodedInputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.AuditLogConfig parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.AuditLogConfig prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * Provides the configuration for logging a type of permissions. - * Example: - * { - * "audit_log_configs": [ - * { - * "log_type": "DATA_READ", - * "exempted_members": [ - * "user:jose@example.com" - * ] - * }, - * { - * "log_type": "DATA_WRITE" - * } - * ] - * } - * This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting - * jose@example.com from DATA_READ logging. - *- * - * Protobuf type {@code google.iam.v1.AuditLogConfig} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * The log type that this config enables. - *- * - *
.google.iam.v1.AuditLogConfig.LogType log_type = 1;
- *
- * @return The enum numeric value on the wire for logType.
- */
- @java.lang.Override
- public int getLogTypeValue() {
- return logType_;
- }
- /**
- *
- *
- * - * The log type that this config enables. - *- * - *
.google.iam.v1.AuditLogConfig.LogType log_type = 1;
- *
- * @param value The enum numeric value on the wire for logType to set.
- * @return This builder for chaining.
- */
- public Builder setLogTypeValue(int value) {
-
- logType_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The log type that this config enables. - *- * - *
.google.iam.v1.AuditLogConfig.LogType log_type = 1;
- *
- * @return The logType.
- */
- @java.lang.Override
- public com.google.iam.v1.AuditLogConfig.LogType getLogType() {
- @SuppressWarnings("deprecation")
- com.google.iam.v1.AuditLogConfig.LogType result =
- com.google.iam.v1.AuditLogConfig.LogType.valueOf(logType_);
- return result == null ? com.google.iam.v1.AuditLogConfig.LogType.UNRECOGNIZED : result;
- }
- /**
- *
- *
- * - * The log type that this config enables. - *- * - *
.google.iam.v1.AuditLogConfig.LogType log_type = 1;
- *
- * @param value The logType to set.
- * @return This builder for chaining.
- */
- public Builder setLogType(com.google.iam.v1.AuditLogConfig.LogType value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- logType_ = value.getNumber();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The log type that this config enables. - *- * - *
.google.iam.v1.AuditLogConfig.LogType log_type = 1;
- *
- * @return This builder for chaining.
- */
- public Builder clearLogType() {
-
- logType_ = 0;
- onChanged();
- return this;
- }
-
- private com.google.protobuf.LazyStringList exemptedMembers_ =
- com.google.protobuf.LazyStringArrayList.EMPTY;
-
- private void ensureExemptedMembersIsMutable() {
- if (!((bitField0_ & 0x00000001) != 0)) {
- exemptedMembers_ = new com.google.protobuf.LazyStringArrayList(exemptedMembers_);
- bitField0_ |= 0x00000001;
- }
- }
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @return A list containing the exemptedMembers.
- */
- public com.google.protobuf.ProtocolStringList getExemptedMembersList() {
- return exemptedMembers_.getUnmodifiableView();
- }
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @return The count of exemptedMembers.
- */
- public int getExemptedMembersCount() {
- return exemptedMembers_.size();
- }
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @param index The index of the element to return.
- * @return The exemptedMembers at the given index.
- */
- public java.lang.String getExemptedMembers(int index) {
- return exemptedMembers_.get(index);
- }
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @param index The index of the value to return.
- * @return The bytes of the exemptedMembers at the given index.
- */
- public com.google.protobuf.ByteString getExemptedMembersBytes(int index) {
- return exemptedMembers_.getByteString(index);
- }
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @param index The index to set the value at.
- * @param value The exemptedMembers to set.
- * @return This builder for chaining.
- */
- public Builder setExemptedMembers(int index, java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureExemptedMembersIsMutable();
- exemptedMembers_.set(index, value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @param value The exemptedMembers to add.
- * @return This builder for chaining.
- */
- public Builder addExemptedMembers(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureExemptedMembersIsMutable();
- exemptedMembers_.add(value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @param values The exemptedMembers to add.
- * @return This builder for chaining.
- */
- public Builder addAllExemptedMembers(java.lang.Iterable- * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @return This builder for chaining.
- */
- public Builder clearExemptedMembers() {
- exemptedMembers_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000001);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @param value The bytes of the exemptedMembers to add.
- * @return This builder for chaining.
- */
- public Builder addExemptedMembersBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
- ensureExemptedMembersIsMutable();
- exemptedMembers_.add(value);
- onChanged();
- return this;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v1.AuditLogConfig)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v1.AuditLogConfig)
- private static final com.google.iam.v1.AuditLogConfig DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v1.AuditLogConfig();
- }
-
- public static com.google.iam.v1.AuditLogConfig getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * The log type that this config enables. - *- * - *
.google.iam.v1.AuditLogConfig.LogType log_type = 1;
- *
- * @return The enum numeric value on the wire for logType.
- */
- int getLogTypeValue();
- /**
- *
- *
- * - * The log type that this config enables. - *- * - *
.google.iam.v1.AuditLogConfig.LogType log_type = 1;
- *
- * @return The logType.
- */
- com.google.iam.v1.AuditLogConfig.LogType getLogType();
-
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @return A list containing the exemptedMembers.
- */
- java.util.List- * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @return The count of exemptedMembers.
- */
- int getExemptedMembersCount();
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @param index The index of the element to return.
- * @return The exemptedMembers at the given index.
- */
- java.lang.String getExemptedMembers(int index);
- /**
- *
- *
- * - * Specifies the identities that do not cause logging for this type of - * permission. - * Follows the same format of [Binding.members][google.iam.v1.Binding.members]. - *- * - *
repeated string exempted_members = 2;
- *
- * @param index The index of the value to return.
- * @return The bytes of the exemptedMembers at the given index.
- */
- com.google.protobuf.ByteString getExemptedMembersBytes(int index);
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/Binding.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/Binding.java
deleted file mode 100644
index d4cb1d80..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/Binding.java
+++ /dev/null
@@ -1,1622 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/policy.proto
-
-package com.google.iam.v1;
-
-/**
- *
- *
- * - * Associates `members`, or principals, with a `role`. - *- * - * Protobuf type {@code google.iam.v1.Binding} - */ -public final class Binding extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.Binding) - BindingOrBuilder { - private static final long serialVersionUID = 0L; - // Use Binding.newBuilder() to construct. - private Binding(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private Binding() { - role_ = ""; - members_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Binding(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Binding_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Binding_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.Binding.class, com.google.iam.v1.Binding.Builder.class); - } - - public static final int ROLE_FIELD_NUMBER = 1; - private volatile java.lang.Object role_; - /** - * - * - *
- * Role that is assigned to the list of `members`, or principals. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - *- * - *
string role = 1;
- *
- * @return The role.
- */
- @java.lang.Override
- public java.lang.String getRole() {
- java.lang.Object ref = role_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- role_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * Role that is assigned to the list of `members`, or principals. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - *- * - *
string role = 1;
- *
- * @return The bytes for role.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getRoleBytes() {
- java.lang.Object ref = role_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- role_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- public static final int MEMBERS_FIELD_NUMBER = 2;
- private com.google.protobuf.LazyStringList members_;
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @return A list containing the members.
- */
- public com.google.protobuf.ProtocolStringList getMembersList() {
- return members_;
- }
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @return The count of members.
- */
- public int getMembersCount() {
- return members_.size();
- }
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @param index The index of the element to return.
- * @return The members at the given index.
- */
- public java.lang.String getMembers(int index) {
- return members_.get(index);
- }
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @param index The index of the value to return.
- * @return The bytes of the members at the given index.
- */
- public com.google.protobuf.ByteString getMembersBytes(int index) {
- return members_.getByteString(index);
- }
-
- public static final int CONDITION_FIELD_NUMBER = 3;
- private com.google.type.Expr condition_;
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- *
- * @return Whether the condition field is set.
- */
- @java.lang.Override
- public boolean hasCondition() {
- return condition_ != null;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- *
- * @return The condition.
- */
- @java.lang.Override
- public com.google.type.Expr getCondition() {
- return condition_ == null ? com.google.type.Expr.getDefaultInstance() : condition_;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- */
- @java.lang.Override
- public com.google.type.ExprOrBuilder getConditionOrBuilder() {
- return getCondition();
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(role_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 1, role_);
- }
- for (int i = 0; i < members_.size(); i++) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 2, members_.getRaw(i));
- }
- if (condition_ != null) {
- output.writeMessage(3, getCondition());
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(role_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, role_);
- }
- {
- int dataSize = 0;
- for (int i = 0; i < members_.size(); i++) {
- dataSize += computeStringSizeNoTag(members_.getRaw(i));
- }
- size += dataSize;
- size += 1 * getMembersList().size();
- }
- if (condition_ != null) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCondition());
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.Binding)) {
- return super.equals(obj);
- }
- com.google.iam.v1.Binding other = (com.google.iam.v1.Binding) obj;
-
- if (!getRole().equals(other.getRole())) return false;
- if (!getMembersList().equals(other.getMembersList())) return false;
- if (hasCondition() != other.hasCondition()) return false;
- if (hasCondition()) {
- if (!getCondition().equals(other.getCondition())) return false;
- }
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + ROLE_FIELD_NUMBER;
- hash = (53 * hash) + getRole().hashCode();
- if (getMembersCount() > 0) {
- hash = (37 * hash) + MEMBERS_FIELD_NUMBER;
- hash = (53 * hash) + getMembersList().hashCode();
- }
- if (hasCondition()) {
- hash = (37 * hash) + CONDITION_FIELD_NUMBER;
- hash = (53 * hash) + getCondition().hashCode();
- }
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.Binding parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.Binding parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.Binding parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.Binding parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.Binding parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.Binding parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.Binding parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.Binding parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.Binding parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.Binding parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.Binding parseFrom(com.google.protobuf.CodedInputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.Binding parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.Binding prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * Associates `members`, or principals, with a `role`. - *- * - * Protobuf type {@code google.iam.v1.Binding} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * Role that is assigned to the list of `members`, or principals. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - *- * - *
string role = 1;
- *
- * @return The role.
- */
- public java.lang.String getRole() {
- java.lang.Object ref = role_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- role_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * Role that is assigned to the list of `members`, or principals. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - *- * - *
string role = 1;
- *
- * @return The bytes for role.
- */
- public com.google.protobuf.ByteString getRoleBytes() {
- java.lang.Object ref = role_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- role_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * Role that is assigned to the list of `members`, or principals. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - *- * - *
string role = 1;
- *
- * @param value The role to set.
- * @return This builder for chaining.
- */
- public Builder setRole(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- role_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Role that is assigned to the list of `members`, or principals. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - *- * - *
string role = 1;
- *
- * @return This builder for chaining.
- */
- public Builder clearRole() {
-
- role_ = getDefaultInstance().getRole();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Role that is assigned to the list of `members`, or principals. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - *- * - *
string role = 1;
- *
- * @param value The bytes for role to set.
- * @return This builder for chaining.
- */
- public Builder setRoleBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- role_ = value;
- onChanged();
- return this;
- }
-
- private com.google.protobuf.LazyStringList members_ =
- com.google.protobuf.LazyStringArrayList.EMPTY;
-
- private void ensureMembersIsMutable() {
- if (!((bitField0_ & 0x00000001) != 0)) {
- members_ = new com.google.protobuf.LazyStringArrayList(members_);
- bitField0_ |= 0x00000001;
- }
- }
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @return A list containing the members.
- */
- public com.google.protobuf.ProtocolStringList getMembersList() {
- return members_.getUnmodifiableView();
- }
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @return The count of members.
- */
- public int getMembersCount() {
- return members_.size();
- }
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @param index The index of the element to return.
- * @return The members at the given index.
- */
- public java.lang.String getMembers(int index) {
- return members_.get(index);
- }
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @param index The index of the value to return.
- * @return The bytes of the members at the given index.
- */
- public com.google.protobuf.ByteString getMembersBytes(int index) {
- return members_.getByteString(index);
- }
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @param index The index to set the value at.
- * @param value The members to set.
- * @return This builder for chaining.
- */
- public Builder setMembers(int index, java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureMembersIsMutable();
- members_.set(index, value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @param value The members to add.
- * @return This builder for chaining.
- */
- public Builder addMembers(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureMembersIsMutable();
- members_.add(value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @param values The members to add.
- * @return This builder for chaining.
- */
- public Builder addAllMembers(java.lang.Iterable- * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @return This builder for chaining.
- */
- public Builder clearMembers() {
- members_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000001);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @param value The bytes of the members to add.
- * @return This builder for chaining.
- */
- public Builder addMembersBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
- ensureMembersIsMutable();
- members_.add(value);
- onChanged();
- return this;
- }
-
- private com.google.type.Expr condition_;
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder>
- conditionBuilder_;
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- *
- * @return Whether the condition field is set.
- */
- public boolean hasCondition() {
- return conditionBuilder_ != null || condition_ != null;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- *
- * @return The condition.
- */
- public com.google.type.Expr getCondition() {
- if (conditionBuilder_ == null) {
- return condition_ == null ? com.google.type.Expr.getDefaultInstance() : condition_;
- } else {
- return conditionBuilder_.getMessage();
- }
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- */
- public Builder setCondition(com.google.type.Expr value) {
- if (conditionBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- condition_ = value;
- onChanged();
- } else {
- conditionBuilder_.setMessage(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- */
- public Builder setCondition(com.google.type.Expr.Builder builderForValue) {
- if (conditionBuilder_ == null) {
- condition_ = builderForValue.build();
- onChanged();
- } else {
- conditionBuilder_.setMessage(builderForValue.build());
- }
-
- return this;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- */
- public Builder mergeCondition(com.google.type.Expr value) {
- if (conditionBuilder_ == null) {
- if (condition_ != null) {
- condition_ = com.google.type.Expr.newBuilder(condition_).mergeFrom(value).buildPartial();
- } else {
- condition_ = value;
- }
- onChanged();
- } else {
- conditionBuilder_.mergeFrom(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- */
- public Builder clearCondition() {
- if (conditionBuilder_ == null) {
- condition_ = null;
- onChanged();
- } else {
- condition_ = null;
- conditionBuilder_ = null;
- }
-
- return this;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- */
- public com.google.type.Expr.Builder getConditionBuilder() {
-
- onChanged();
- return getConditionFieldBuilder().getBuilder();
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- */
- public com.google.type.ExprOrBuilder getConditionOrBuilder() {
- if (conditionBuilder_ != null) {
- return conditionBuilder_.getMessageOrBuilder();
- } else {
- return condition_ == null ? com.google.type.Expr.getDefaultInstance() : condition_;
- }
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- */
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder>
- getConditionFieldBuilder() {
- if (conditionBuilder_ == null) {
- conditionBuilder_ =
- new com.google.protobuf.SingleFieldBuilderV3<
- com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder>(
- getCondition(), getParentForChildren(), isClean());
- condition_ = null;
- }
- return conditionBuilder_;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v1.Binding)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v1.Binding)
- private static final com.google.iam.v1.Binding DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v1.Binding();
- }
-
- public static com.google.iam.v1.Binding getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * One delta entry for Binding. Each individual change (only one member in each - * entry) to a binding will be a separate entry. - *- * - * Protobuf type {@code google.iam.v1.BindingDelta} - */ -public final class BindingDelta extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.BindingDelta) - BindingDeltaOrBuilder { - private static final long serialVersionUID = 0L; - // Use BindingDelta.newBuilder() to construct. - private BindingDelta(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private BindingDelta() { - action_ = 0; - role_ = ""; - member_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new BindingDelta(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_BindingDelta_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.PolicyProto - .internal_static_google_iam_v1_BindingDelta_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.BindingDelta.class, com.google.iam.v1.BindingDelta.Builder.class); - } - - /** - * - * - *
- * The type of action performed on a Binding in a policy. - *- * - * Protobuf enum {@code google.iam.v1.BindingDelta.Action} - */ - public enum Action implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
- * Unspecified. - *- * - *
ACTION_UNSPECIFIED = 0;
- */
- ACTION_UNSPECIFIED(0),
- /**
- *
- *
- * - * Addition of a Binding. - *- * - *
ADD = 1;
- */
- ADD(1),
- /**
- *
- *
- * - * Removal of a Binding. - *- * - *
REMOVE = 2;
- */
- REMOVE(2),
- UNRECOGNIZED(-1),
- ;
-
- /**
- *
- *
- * - * Unspecified. - *- * - *
ACTION_UNSPECIFIED = 0;
- */
- public static final int ACTION_UNSPECIFIED_VALUE = 0;
- /**
- *
- *
- * - * Addition of a Binding. - *- * - *
ADD = 1;
- */
- public static final int ADD_VALUE = 1;
- /**
- *
- *
- * - * Removal of a Binding. - *- * - *
REMOVE = 2;
- */
- public static final int REMOVE_VALUE = 2;
-
- public final int getNumber() {
- if (this == UNRECOGNIZED) {
- throw new java.lang.IllegalArgumentException(
- "Can't get the number of an unknown enum value.");
- }
- return value;
- }
-
- /**
- * @param value The numeric wire value of the corresponding enum entry.
- * @return The enum associated with the given numeric wire value.
- * @deprecated Use {@link #forNumber(int)} instead.
- */
- @java.lang.Deprecated
- public static Action valueOf(int value) {
- return forNumber(value);
- }
-
- /**
- * @param value The numeric wire value of the corresponding enum entry.
- * @return The enum associated with the given numeric wire value.
- */
- public static Action forNumber(int value) {
- switch (value) {
- case 0:
- return ACTION_UNSPECIFIED;
- case 1:
- return ADD;
- case 2:
- return REMOVE;
- default:
- return null;
- }
- }
-
- public static com.google.protobuf.Internal.EnumLiteMap- * The action that was performed on a Binding. - * Required - *- * - *
.google.iam.v1.BindingDelta.Action action = 1;
- *
- * @return The enum numeric value on the wire for action.
- */
- @java.lang.Override
- public int getActionValue() {
- return action_;
- }
- /**
- *
- *
- * - * The action that was performed on a Binding. - * Required - *- * - *
.google.iam.v1.BindingDelta.Action action = 1;
- *
- * @return The action.
- */
- @java.lang.Override
- public com.google.iam.v1.BindingDelta.Action getAction() {
- @SuppressWarnings("deprecation")
- com.google.iam.v1.BindingDelta.Action result =
- com.google.iam.v1.BindingDelta.Action.valueOf(action_);
- return result == null ? com.google.iam.v1.BindingDelta.Action.UNRECOGNIZED : result;
- }
-
- public static final int ROLE_FIELD_NUMBER = 2;
- private volatile java.lang.Object role_;
- /**
- *
- *
- * - * Role that is assigned to `members`. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - * Required - *- * - *
string role = 2;
- *
- * @return The role.
- */
- @java.lang.Override
- public java.lang.String getRole() {
- java.lang.Object ref = role_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- role_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * Role that is assigned to `members`. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - * Required - *- * - *
string role = 2;
- *
- * @return The bytes for role.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getRoleBytes() {
- java.lang.Object ref = role_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- role_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- public static final int MEMBER_FIELD_NUMBER = 3;
- private volatile java.lang.Object member_;
- /**
- *
- *
- * - * A single identity requesting access for a Cloud Platform resource. - * Follows the same format of Binding.members. - * Required - *- * - *
string member = 3;
- *
- * @return The member.
- */
- @java.lang.Override
- public java.lang.String getMember() {
- java.lang.Object ref = member_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- member_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * A single identity requesting access for a Cloud Platform resource. - * Follows the same format of Binding.members. - * Required - *- * - *
string member = 3;
- *
- * @return The bytes for member.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getMemberBytes() {
- java.lang.Object ref = member_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- member_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- public static final int CONDITION_FIELD_NUMBER = 4;
- private com.google.type.Expr condition_;
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- *
- * @return Whether the condition field is set.
- */
- @java.lang.Override
- public boolean hasCondition() {
- return condition_ != null;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- *
- * @return The condition.
- */
- @java.lang.Override
- public com.google.type.Expr getCondition() {
- return condition_ == null ? com.google.type.Expr.getDefaultInstance() : condition_;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- */
- @java.lang.Override
- public com.google.type.ExprOrBuilder getConditionOrBuilder() {
- return getCondition();
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (action_ != com.google.iam.v1.BindingDelta.Action.ACTION_UNSPECIFIED.getNumber()) {
- output.writeEnum(1, action_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(role_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 2, role_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(member_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 3, member_);
- }
- if (condition_ != null) {
- output.writeMessage(4, getCondition());
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (action_ != com.google.iam.v1.BindingDelta.Action.ACTION_UNSPECIFIED.getNumber()) {
- size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, action_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(role_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, role_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(member_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, member_);
- }
- if (condition_ != null) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getCondition());
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.BindingDelta)) {
- return super.equals(obj);
- }
- com.google.iam.v1.BindingDelta other = (com.google.iam.v1.BindingDelta) obj;
-
- if (action_ != other.action_) return false;
- if (!getRole().equals(other.getRole())) return false;
- if (!getMember().equals(other.getMember())) return false;
- if (hasCondition() != other.hasCondition()) return false;
- if (hasCondition()) {
- if (!getCondition().equals(other.getCondition())) return false;
- }
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + ACTION_FIELD_NUMBER;
- hash = (53 * hash) + action_;
- hash = (37 * hash) + ROLE_FIELD_NUMBER;
- hash = (53 * hash) + getRole().hashCode();
- hash = (37 * hash) + MEMBER_FIELD_NUMBER;
- hash = (53 * hash) + getMember().hashCode();
- if (hasCondition()) {
- hash = (37 * hash) + CONDITION_FIELD_NUMBER;
- hash = (53 * hash) + getCondition().hashCode();
- }
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.BindingDelta parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.BindingDelta parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.BindingDelta parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.BindingDelta parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.BindingDelta parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.BindingDelta parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.BindingDelta parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.BindingDelta parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.BindingDelta parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.BindingDelta parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.BindingDelta parseFrom(com.google.protobuf.CodedInputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.BindingDelta parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.BindingDelta prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * One delta entry for Binding. Each individual change (only one member in each - * entry) to a binding will be a separate entry. - *- * - * Protobuf type {@code google.iam.v1.BindingDelta} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * The action that was performed on a Binding. - * Required - *- * - *
.google.iam.v1.BindingDelta.Action action = 1;
- *
- * @return The enum numeric value on the wire for action.
- */
- @java.lang.Override
- public int getActionValue() {
- return action_;
- }
- /**
- *
- *
- * - * The action that was performed on a Binding. - * Required - *- * - *
.google.iam.v1.BindingDelta.Action action = 1;
- *
- * @param value The enum numeric value on the wire for action to set.
- * @return This builder for chaining.
- */
- public Builder setActionValue(int value) {
-
- action_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The action that was performed on a Binding. - * Required - *- * - *
.google.iam.v1.BindingDelta.Action action = 1;
- *
- * @return The action.
- */
- @java.lang.Override
- public com.google.iam.v1.BindingDelta.Action getAction() {
- @SuppressWarnings("deprecation")
- com.google.iam.v1.BindingDelta.Action result =
- com.google.iam.v1.BindingDelta.Action.valueOf(action_);
- return result == null ? com.google.iam.v1.BindingDelta.Action.UNRECOGNIZED : result;
- }
- /**
- *
- *
- * - * The action that was performed on a Binding. - * Required - *- * - *
.google.iam.v1.BindingDelta.Action action = 1;
- *
- * @param value The action to set.
- * @return This builder for chaining.
- */
- public Builder setAction(com.google.iam.v1.BindingDelta.Action value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- action_ = value.getNumber();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The action that was performed on a Binding. - * Required - *- * - *
.google.iam.v1.BindingDelta.Action action = 1;
- *
- * @return This builder for chaining.
- */
- public Builder clearAction() {
-
- action_ = 0;
- onChanged();
- return this;
- }
-
- private java.lang.Object role_ = "";
- /**
- *
- *
- * - * Role that is assigned to `members`. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - * Required - *- * - *
string role = 2;
- *
- * @return The role.
- */
- public java.lang.String getRole() {
- java.lang.Object ref = role_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- role_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * Role that is assigned to `members`. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - * Required - *- * - *
string role = 2;
- *
- * @return The bytes for role.
- */
- public com.google.protobuf.ByteString getRoleBytes() {
- java.lang.Object ref = role_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- role_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * Role that is assigned to `members`. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - * Required - *- * - *
string role = 2;
- *
- * @param value The role to set.
- * @return This builder for chaining.
- */
- public Builder setRole(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- role_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Role that is assigned to `members`. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - * Required - *- * - *
string role = 2;
- *
- * @return This builder for chaining.
- */
- public Builder clearRole() {
-
- role_ = getDefaultInstance().getRole();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Role that is assigned to `members`. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - * Required - *- * - *
string role = 2;
- *
- * @param value The bytes for role to set.
- * @return This builder for chaining.
- */
- public Builder setRoleBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- role_ = value;
- onChanged();
- return this;
- }
-
- private java.lang.Object member_ = "";
- /**
- *
- *
- * - * A single identity requesting access for a Cloud Platform resource. - * Follows the same format of Binding.members. - * Required - *- * - *
string member = 3;
- *
- * @return The member.
- */
- public java.lang.String getMember() {
- java.lang.Object ref = member_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- member_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * A single identity requesting access for a Cloud Platform resource. - * Follows the same format of Binding.members. - * Required - *- * - *
string member = 3;
- *
- * @return The bytes for member.
- */
- public com.google.protobuf.ByteString getMemberBytes() {
- java.lang.Object ref = member_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- member_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * A single identity requesting access for a Cloud Platform resource. - * Follows the same format of Binding.members. - * Required - *- * - *
string member = 3;
- *
- * @param value The member to set.
- * @return This builder for chaining.
- */
- public Builder setMember(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- member_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * A single identity requesting access for a Cloud Platform resource. - * Follows the same format of Binding.members. - * Required - *- * - *
string member = 3;
- *
- * @return This builder for chaining.
- */
- public Builder clearMember() {
-
- member_ = getDefaultInstance().getMember();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * A single identity requesting access for a Cloud Platform resource. - * Follows the same format of Binding.members. - * Required - *- * - *
string member = 3;
- *
- * @param value The bytes for member to set.
- * @return This builder for chaining.
- */
- public Builder setMemberBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- member_ = value;
- onChanged();
- return this;
- }
-
- private com.google.type.Expr condition_;
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder>
- conditionBuilder_;
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- *
- * @return Whether the condition field is set.
- */
- public boolean hasCondition() {
- return conditionBuilder_ != null || condition_ != null;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- *
- * @return The condition.
- */
- public com.google.type.Expr getCondition() {
- if (conditionBuilder_ == null) {
- return condition_ == null ? com.google.type.Expr.getDefaultInstance() : condition_;
- } else {
- return conditionBuilder_.getMessage();
- }
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- */
- public Builder setCondition(com.google.type.Expr value) {
- if (conditionBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- condition_ = value;
- onChanged();
- } else {
- conditionBuilder_.setMessage(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- */
- public Builder setCondition(com.google.type.Expr.Builder builderForValue) {
- if (conditionBuilder_ == null) {
- condition_ = builderForValue.build();
- onChanged();
- } else {
- conditionBuilder_.setMessage(builderForValue.build());
- }
-
- return this;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- */
- public Builder mergeCondition(com.google.type.Expr value) {
- if (conditionBuilder_ == null) {
- if (condition_ != null) {
- condition_ = com.google.type.Expr.newBuilder(condition_).mergeFrom(value).buildPartial();
- } else {
- condition_ = value;
- }
- onChanged();
- } else {
- conditionBuilder_.mergeFrom(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- */
- public Builder clearCondition() {
- if (conditionBuilder_ == null) {
- condition_ = null;
- onChanged();
- } else {
- condition_ = null;
- conditionBuilder_ = null;
- }
-
- return this;
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- */
- public com.google.type.Expr.Builder getConditionBuilder() {
-
- onChanged();
- return getConditionFieldBuilder().getBuilder();
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- */
- public com.google.type.ExprOrBuilder getConditionOrBuilder() {
- if (conditionBuilder_ != null) {
- return conditionBuilder_.getMessageOrBuilder();
- } else {
- return condition_ == null ? com.google.type.Expr.getDefaultInstance() : condition_;
- }
- }
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- */
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder>
- getConditionFieldBuilder() {
- if (conditionBuilder_ == null) {
- conditionBuilder_ =
- new com.google.protobuf.SingleFieldBuilderV3<
- com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder>(
- getCondition(), getParentForChildren(), isClean());
- condition_ = null;
- }
- return conditionBuilder_;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v1.BindingDelta)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v1.BindingDelta)
- private static final com.google.iam.v1.BindingDelta DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v1.BindingDelta();
- }
-
- public static com.google.iam.v1.BindingDelta getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * The action that was performed on a Binding. - * Required - *- * - *
.google.iam.v1.BindingDelta.Action action = 1;
- *
- * @return The enum numeric value on the wire for action.
- */
- int getActionValue();
- /**
- *
- *
- * - * The action that was performed on a Binding. - * Required - *- * - *
.google.iam.v1.BindingDelta.Action action = 1;
- *
- * @return The action.
- */
- com.google.iam.v1.BindingDelta.Action getAction();
-
- /**
- *
- *
- * - * Role that is assigned to `members`. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - * Required - *- * - *
string role = 2;
- *
- * @return The role.
- */
- java.lang.String getRole();
- /**
- *
- *
- * - * Role that is assigned to `members`. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - * Required - *- * - *
string role = 2;
- *
- * @return The bytes for role.
- */
- com.google.protobuf.ByteString getRoleBytes();
-
- /**
- *
- *
- * - * A single identity requesting access for a Cloud Platform resource. - * Follows the same format of Binding.members. - * Required - *- * - *
string member = 3;
- *
- * @return The member.
- */
- java.lang.String getMember();
- /**
- *
- *
- * - * A single identity requesting access for a Cloud Platform resource. - * Follows the same format of Binding.members. - * Required - *- * - *
string member = 3;
- *
- * @return The bytes for member.
- */
- com.google.protobuf.ByteString getMemberBytes();
-
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- *
- * @return Whether the condition field is set.
- */
- boolean hasCondition();
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- *
- * @return The condition.
- */
- com.google.type.Expr getCondition();
- /**
- *
- *
- * - * The condition that is associated with this binding. - *- * - *
.google.type.Expr condition = 4;
- */
- com.google.type.ExprOrBuilder getConditionOrBuilder();
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingOrBuilder.java
deleted file mode 100644
index b5e660fa..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingOrBuilder.java
+++ /dev/null
@@ -1,282 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/policy.proto
-
-package com.google.iam.v1;
-
-public interface BindingOrBuilder
- extends
- // @@protoc_insertion_point(interface_extends:google.iam.v1.Binding)
- com.google.protobuf.MessageOrBuilder {
-
- /**
- *
- *
- * - * Role that is assigned to the list of `members`, or principals. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - *- * - *
string role = 1;
- *
- * @return The role.
- */
- java.lang.String getRole();
- /**
- *
- *
- * - * Role that is assigned to the list of `members`, or principals. - * For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - *- * - *
string role = 1;
- *
- * @return The bytes for role.
- */
- com.google.protobuf.ByteString getRoleBytes();
-
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @return A list containing the members.
- */
- java.util.List- * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @return The count of members.
- */
- int getMembersCount();
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @param index The index of the element to return.
- * @return The members at the given index.
- */
- java.lang.String getMembers(int index);
- /**
- *
- *
- * - * Specifies the principals requesting access for a Cloud Platform resource. - * `members` can have the following values: - * * `allUsers`: A special identifier that represents anyone who is - * on the internet; with or without a Google account. - * * `allAuthenticatedUsers`: A special identifier that represents anyone - * who is authenticated with a Google account or a service account. - * * `user:{emailid}`: An email address that represents a specific Google - * account. For example, `alice@example.com` . - * * `serviceAccount:{emailid}`: An email address that represents a service - * account. For example, `my-other-app@appspot.gserviceaccount.com`. - * * `group:{emailid}`: An email address that represents a Google group. - * For example, `admins@example.com`. - * * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a user that has been recently deleted. For - * example, `alice@example.com?uid=123456789012345678901`. If the user is - * recovered, this value reverts to `user:{emailid}` and the recovered user - * retains the role in the binding. - * * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus - * unique identifier) representing a service account that has been recently - * deleted. For example, - * `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - * If the service account is undeleted, this value reverts to - * `serviceAccount:{emailid}` and the undeleted service account retains the - * role in the binding. - * * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique - * identifier) representing a Google group that has been recently - * deleted. For example, `admins@example.com?uid=123456789012345678901`. If - * the group is recovered, this value reverts to `group:{emailid}` and the - * recovered group retains the role in the binding. - * * `domain:{domain}`: The G Suite domain (primary) that represents all the - * users of that domain. For example, `google.com` or `example.com`. - *- * - *
repeated string members = 2;
- *
- * @param index The index of the value to return.
- * @return The bytes of the members at the given index.
- */
- com.google.protobuf.ByteString getMembersBytes(int index);
-
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- *
- * @return Whether the condition field is set.
- */
- boolean hasCondition();
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- *
- * @return The condition.
- */
- com.google.type.Expr getCondition();
- /**
- *
- *
- * - * The condition that is associated with this binding. - * If the condition evaluates to `true`, then this binding applies to the - * current request. - * If the condition evaluates to `false`, then this binding does not apply to - * the current request. However, a different role binding might grant the same - * role to one or more of the principals in this binding. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
.google.type.Expr condition = 3;
- */
- com.google.type.ExprOrBuilder getConditionOrBuilder();
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetIamPolicyRequest.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetIamPolicyRequest.java
deleted file mode 100644
index 883feeaa..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetIamPolicyRequest.java
+++ /dev/null
@@ -1,910 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/iam_policy.proto
-
-package com.google.iam.v1;
-
-/**
- *
- *
- * - * Request message for `GetIamPolicy` method. - *- * - * Protobuf type {@code google.iam.v1.GetIamPolicyRequest} - */ -public final class GetIamPolicyRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.GetIamPolicyRequest) - GetIamPolicyRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use GetIamPolicyRequest.newBuilder() to construct. - private GetIamPolicyRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private GetIamPolicyRequest() { - resource_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new GetIamPolicyRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.IamPolicyProto - .internal_static_google_iam_v1_GetIamPolicyRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.IamPolicyProto - .internal_static_google_iam_v1_GetIamPolicyRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.GetIamPolicyRequest.class, - com.google.iam.v1.GetIamPolicyRequest.Builder.class); - } - - public static final int RESOURCE_FIELD_NUMBER = 1; - private volatile java.lang.Object resource_; - /** - * - * - *
- * REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The resource.
- */
- @java.lang.Override
- public java.lang.String getResource() {
- java.lang.Object ref = resource_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- resource_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The bytes for resource.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getResourceBytes() {
- java.lang.Object ref = resource_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- resource_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- public static final int OPTIONS_FIELD_NUMBER = 2;
- private com.google.iam.v1.GetPolicyOptions options_;
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- *
- * @return Whether the options field is set.
- */
- @java.lang.Override
- public boolean hasOptions() {
- return options_ != null;
- }
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- *
- * @return The options.
- */
- @java.lang.Override
- public com.google.iam.v1.GetPolicyOptions getOptions() {
- return options_ == null ? com.google.iam.v1.GetPolicyOptions.getDefaultInstance() : options_;
- }
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- */
- @java.lang.Override
- public com.google.iam.v1.GetPolicyOptionsOrBuilder getOptionsOrBuilder() {
- return getOptions();
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resource_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resource_);
- }
- if (options_ != null) {
- output.writeMessage(2, getOptions());
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resource_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, resource_);
- }
- if (options_ != null) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getOptions());
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.GetIamPolicyRequest)) {
- return super.equals(obj);
- }
- com.google.iam.v1.GetIamPolicyRequest other = (com.google.iam.v1.GetIamPolicyRequest) obj;
-
- if (!getResource().equals(other.getResource())) return false;
- if (hasOptions() != other.hasOptions()) return false;
- if (hasOptions()) {
- if (!getOptions().equals(other.getOptions())) return false;
- }
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + RESOURCE_FIELD_NUMBER;
- hash = (53 * hash) + getResource().hashCode();
- if (hasOptions()) {
- hash = (37 * hash) + OPTIONS_FIELD_NUMBER;
- hash = (53 * hash) + getOptions().hashCode();
- }
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
- com.google.protobuf.CodedInputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.GetIamPolicyRequest prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * Request message for `GetIamPolicy` method. - *- * - * Protobuf type {@code google.iam.v1.GetIamPolicyRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The resource.
- */
- public java.lang.String getResource() {
- java.lang.Object ref = resource_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- resource_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The bytes for resource.
- */
- public com.google.protobuf.ByteString getResourceBytes() {
- java.lang.Object ref = resource_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- resource_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @param value The resource to set.
- * @return This builder for chaining.
- */
- public Builder setResource(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- resource_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return This builder for chaining.
- */
- public Builder clearResource() {
-
- resource_ = getDefaultInstance().getResource();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @param value The bytes for resource to set.
- * @return This builder for chaining.
- */
- public Builder setResourceBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- resource_ = value;
- onChanged();
- return this;
- }
-
- private com.google.iam.v1.GetPolicyOptions options_;
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.iam.v1.GetPolicyOptions,
- com.google.iam.v1.GetPolicyOptions.Builder,
- com.google.iam.v1.GetPolicyOptionsOrBuilder>
- optionsBuilder_;
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- *
- * @return Whether the options field is set.
- */
- public boolean hasOptions() {
- return optionsBuilder_ != null || options_ != null;
- }
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- *
- * @return The options.
- */
- public com.google.iam.v1.GetPolicyOptions getOptions() {
- if (optionsBuilder_ == null) {
- return options_ == null
- ? com.google.iam.v1.GetPolicyOptions.getDefaultInstance()
- : options_;
- } else {
- return optionsBuilder_.getMessage();
- }
- }
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- */
- public Builder setOptions(com.google.iam.v1.GetPolicyOptions value) {
- if (optionsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- options_ = value;
- onChanged();
- } else {
- optionsBuilder_.setMessage(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- */
- public Builder setOptions(com.google.iam.v1.GetPolicyOptions.Builder builderForValue) {
- if (optionsBuilder_ == null) {
- options_ = builderForValue.build();
- onChanged();
- } else {
- optionsBuilder_.setMessage(builderForValue.build());
- }
-
- return this;
- }
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- */
- public Builder mergeOptions(com.google.iam.v1.GetPolicyOptions value) {
- if (optionsBuilder_ == null) {
- if (options_ != null) {
- options_ =
- com.google.iam.v1.GetPolicyOptions.newBuilder(options_)
- .mergeFrom(value)
- .buildPartial();
- } else {
- options_ = value;
- }
- onChanged();
- } else {
- optionsBuilder_.mergeFrom(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- */
- public Builder clearOptions() {
- if (optionsBuilder_ == null) {
- options_ = null;
- onChanged();
- } else {
- options_ = null;
- optionsBuilder_ = null;
- }
-
- return this;
- }
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- */
- public com.google.iam.v1.GetPolicyOptions.Builder getOptionsBuilder() {
-
- onChanged();
- return getOptionsFieldBuilder().getBuilder();
- }
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- */
- public com.google.iam.v1.GetPolicyOptionsOrBuilder getOptionsOrBuilder() {
- if (optionsBuilder_ != null) {
- return optionsBuilder_.getMessageOrBuilder();
- } else {
- return options_ == null
- ? com.google.iam.v1.GetPolicyOptions.getDefaultInstance()
- : options_;
- }
- }
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- */
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.iam.v1.GetPolicyOptions,
- com.google.iam.v1.GetPolicyOptions.Builder,
- com.google.iam.v1.GetPolicyOptionsOrBuilder>
- getOptionsFieldBuilder() {
- if (optionsBuilder_ == null) {
- optionsBuilder_ =
- new com.google.protobuf.SingleFieldBuilderV3<
- com.google.iam.v1.GetPolicyOptions,
- com.google.iam.v1.GetPolicyOptions.Builder,
- com.google.iam.v1.GetPolicyOptionsOrBuilder>(
- getOptions(), getParentForChildren(), isClean());
- options_ = null;
- }
- return optionsBuilder_;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v1.GetIamPolicyRequest)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v1.GetIamPolicyRequest)
- private static final com.google.iam.v1.GetIamPolicyRequest DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v1.GetIamPolicyRequest();
- }
-
- public static com.google.iam.v1.GetIamPolicyRequest getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The resource.
- */
- java.lang.String getResource();
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The bytes for resource.
- */
- com.google.protobuf.ByteString getResourceBytes();
-
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- *
- * @return Whether the options field is set.
- */
- boolean hasOptions();
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- *
- * @return The options.
- */
- com.google.iam.v1.GetPolicyOptions getOptions();
- /**
- *
- *
- * - * OPTIONAL: A `GetPolicyOptions` object for specifying options to - * `GetIamPolicy`. - *- * - *
.google.iam.v1.GetPolicyOptions options = 2;
- */
- com.google.iam.v1.GetPolicyOptionsOrBuilder getOptionsOrBuilder();
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetPolicyOptions.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetPolicyOptions.java
deleted file mode 100644
index 1c427ecb..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetPolicyOptions.java
+++ /dev/null
@@ -1,574 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/options.proto
-
-package com.google.iam.v1;
-
-/**
- *
- *
- * - * Encapsulates settings provided to GetIamPolicy. - *- * - * Protobuf type {@code google.iam.v1.GetPolicyOptions} - */ -public final class GetPolicyOptions extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.GetPolicyOptions) - GetPolicyOptionsOrBuilder { - private static final long serialVersionUID = 0L; - // Use GetPolicyOptions.newBuilder() to construct. - private GetPolicyOptions(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private GetPolicyOptions() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new GetPolicyOptions(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.OptionsProto.internal_static_google_iam_v1_GetPolicyOptions_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.OptionsProto - .internal_static_google_iam_v1_GetPolicyOptions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.GetPolicyOptions.class, - com.google.iam.v1.GetPolicyOptions.Builder.class); - } - - public static final int REQUESTED_POLICY_VERSION_FIELD_NUMBER = 1; - private int requestedPolicyVersion_; - /** - * - * - *
- * Optional. The maximum policy version that will be used to format the - * policy. - * Valid values are 0, 1, and 3. Requests specifying an invalid value will be - * rejected. - * Requests for policies with any conditional role bindings must specify - * version 3. Policies with no conditional role bindings may specify any valid - * value or leave the field unset. - * The policy in the response might use the policy version that you specified, - * or it might use a lower policy version. For example, if you specify version - * 3, but the policy has no conditional role bindings, the response uses - * version 1. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
int32 requested_policy_version = 1;
- *
- * @return The requestedPolicyVersion.
- */
- @java.lang.Override
- public int getRequestedPolicyVersion() {
- return requestedPolicyVersion_;
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (requestedPolicyVersion_ != 0) {
- output.writeInt32(1, requestedPolicyVersion_);
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (requestedPolicyVersion_ != 0) {
- size += com.google.protobuf.CodedOutputStream.computeInt32Size(1, requestedPolicyVersion_);
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.GetPolicyOptions)) {
- return super.equals(obj);
- }
- com.google.iam.v1.GetPolicyOptions other = (com.google.iam.v1.GetPolicyOptions) obj;
-
- if (getRequestedPolicyVersion() != other.getRequestedPolicyVersion()) return false;
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + REQUESTED_POLICY_VERSION_FIELD_NUMBER;
- hash = (53 * hash) + getRequestedPolicyVersion();
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseFrom(
- com.google.protobuf.CodedInputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.GetPolicyOptions parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.GetPolicyOptions prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * Encapsulates settings provided to GetIamPolicy. - *- * - * Protobuf type {@code google.iam.v1.GetPolicyOptions} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * Optional. The maximum policy version that will be used to format the - * policy. - * Valid values are 0, 1, and 3. Requests specifying an invalid value will be - * rejected. - * Requests for policies with any conditional role bindings must specify - * version 3. Policies with no conditional role bindings may specify any valid - * value or leave the field unset. - * The policy in the response might use the policy version that you specified, - * or it might use a lower policy version. For example, if you specify version - * 3, but the policy has no conditional role bindings, the response uses - * version 1. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
int32 requested_policy_version = 1;
- *
- * @return The requestedPolicyVersion.
- */
- @java.lang.Override
- public int getRequestedPolicyVersion() {
- return requestedPolicyVersion_;
- }
- /**
- *
- *
- * - * Optional. The maximum policy version that will be used to format the - * policy. - * Valid values are 0, 1, and 3. Requests specifying an invalid value will be - * rejected. - * Requests for policies with any conditional role bindings must specify - * version 3. Policies with no conditional role bindings may specify any valid - * value or leave the field unset. - * The policy in the response might use the policy version that you specified, - * or it might use a lower policy version. For example, if you specify version - * 3, but the policy has no conditional role bindings, the response uses - * version 1. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
int32 requested_policy_version = 1;
- *
- * @param value The requestedPolicyVersion to set.
- * @return This builder for chaining.
- */
- public Builder setRequestedPolicyVersion(int value) {
-
- requestedPolicyVersion_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Optional. The maximum policy version that will be used to format the - * policy. - * Valid values are 0, 1, and 3. Requests specifying an invalid value will be - * rejected. - * Requests for policies with any conditional role bindings must specify - * version 3. Policies with no conditional role bindings may specify any valid - * value or leave the field unset. - * The policy in the response might use the policy version that you specified, - * or it might use a lower policy version. For example, if you specify version - * 3, but the policy has no conditional role bindings, the response uses - * version 1. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
int32 requested_policy_version = 1;
- *
- * @return This builder for chaining.
- */
- public Builder clearRequestedPolicyVersion() {
-
- requestedPolicyVersion_ = 0;
- onChanged();
- return this;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v1.GetPolicyOptions)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v1.GetPolicyOptions)
- private static final com.google.iam.v1.GetPolicyOptions DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v1.GetPolicyOptions();
- }
-
- public static com.google.iam.v1.GetPolicyOptions getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * Optional. The maximum policy version that will be used to format the - * policy. - * Valid values are 0, 1, and 3. Requests specifying an invalid value will be - * rejected. - * Requests for policies with any conditional role bindings must specify - * version 3. Policies with no conditional role bindings may specify any valid - * value or leave the field unset. - * The policy in the response might use the policy version that you specified, - * or it might use a lower policy version. For example, if you specify version - * 3, but the policy has no conditional role bindings, the response uses - * version 1. - * To learn which resources support conditions in their IAM policies, see the - * [IAM - * documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
int32 requested_policy_version = 1;
- *
- * @return The requestedPolicyVersion.
- */
- int getRequestedPolicyVersion();
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/IamPolicyProto.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/IamPolicyProto.java
deleted file mode 100644
index 57652c10..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/IamPolicyProto.java
+++ /dev/null
@@ -1,149 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/iam_policy.proto
-
-package com.google.iam.v1;
-
-public final class IamPolicyProto {
- private IamPolicyProto() {}
-
- public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {}
-
- public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) {
- registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry);
- }
-
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_SetIamPolicyRequest_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_SetIamPolicyRequest_fieldAccessorTable;
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_GetIamPolicyRequest_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_GetIamPolicyRequest_fieldAccessorTable;
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_TestIamPermissionsRequest_fieldAccessorTable;
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_TestIamPermissionsResponse_fieldAccessorTable;
-
- public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
- return descriptor;
- }
-
- private static com.google.protobuf.Descriptors.FileDescriptor descriptor;
-
- static {
- java.lang.String[] descriptorData = {
- "\n\036google/iam/v1/iam_policy.proto\022\rgoogle"
- + ".iam.v1\032\034google/api/annotations.proto\032\027g"
- + "oogle/api/client.proto\032\037google/api/field"
- + "_behavior.proto\032\031google/api/resource.pro"
- + "to\032\033google/iam/v1/options.proto\032\032google/"
- + "iam/v1/policy.proto\032 google/protobuf/fie"
- + "ld_mask.proto\"\217\001\n\023SetIamPolicyRequest\022\033\n"
- + "\010resource\030\001 \001(\tB\t\340A\002\372A\003\n\001*\022*\n\006policy\030\002 \001"
- + "(\0132\025.google.iam.v1.PolicyB\003\340A\002\022/\n\013update"
- + "_mask\030\003 \001(\0132\032.google.protobuf.FieldMask\""
- + "d\n\023GetIamPolicyRequest\022\033\n\010resource\030\001 \001(\t"
- + "B\t\340A\002\372A\003\n\001*\0220\n\007options\030\002 \001(\0132\037.google.ia"
- + "m.v1.GetPolicyOptions\"R\n\031TestIamPermissi"
- + "onsRequest\022\033\n\010resource\030\001 \001(\tB\t\340A\002\372A\003\n\001*\022"
- + "\030\n\013permissions\030\002 \003(\tB\003\340A\002\"1\n\032TestIamPerm"
- + "issionsResponse\022\023\n\013permissions\030\001 \003(\t2\264\003\n"
- + "\tIAMPolicy\022t\n\014SetIamPolicy\022\".google.iam."
- + "v1.SetIamPolicyRequest\032\025.google.iam.v1.P"
- + "olicy\")\202\323\344\223\002#\"\036/v1/{resource=**}:setIamP"
- + "olicy:\001*\022t\n\014GetIamPolicy\022\".google.iam.v1"
- + ".GetIamPolicyRequest\032\025.google.iam.v1.Pol"
- + "icy\")\202\323\344\223\002#\"\036/v1/{resource=**}:getIamPol"
- + "icy:\001*\022\232\001\n\022TestIamPermissions\022(.google.i"
- + "am.v1.TestIamPermissionsRequest\032).google"
- + ".iam.v1.TestIamPermissionsResponse\"/\202\323\344\223"
- + "\002)\"$/v1/{resource=**}:testIamPermissions"
- + ":\001*\032\036\312A\033iam-meta-api.googleapis.comB\206\001\n\021"
- + "com.google.iam.v1B\016IamPolicyProtoP\001Z0goo"
- + "gle.golang.org/genproto/googleapis/iam/v"
- + "1;iam\370\001\001\252\002\023Google.Cloud.Iam.V1\312\002\023Google\\"
- + "Cloud\\Iam\\V1b\006proto3"
- };
- descriptor =
- com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom(
- descriptorData,
- new com.google.protobuf.Descriptors.FileDescriptor[] {
- com.google.api.AnnotationsProto.getDescriptor(),
- com.google.api.ClientProto.getDescriptor(),
- com.google.api.FieldBehaviorProto.getDescriptor(),
- com.google.api.ResourceProto.getDescriptor(),
- com.google.iam.v1.OptionsProto.getDescriptor(),
- com.google.iam.v1.PolicyProto.getDescriptor(),
- com.google.protobuf.FieldMaskProto.getDescriptor(),
- });
- internal_static_google_iam_v1_SetIamPolicyRequest_descriptor =
- getDescriptor().getMessageTypes().get(0);
- internal_static_google_iam_v1_SetIamPolicyRequest_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_SetIamPolicyRequest_descriptor,
- new java.lang.String[] {
- "Resource", "Policy", "UpdateMask",
- });
- internal_static_google_iam_v1_GetIamPolicyRequest_descriptor =
- getDescriptor().getMessageTypes().get(1);
- internal_static_google_iam_v1_GetIamPolicyRequest_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_GetIamPolicyRequest_descriptor,
- new java.lang.String[] {
- "Resource", "Options",
- });
- internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor =
- getDescriptor().getMessageTypes().get(2);
- internal_static_google_iam_v1_TestIamPermissionsRequest_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor,
- new java.lang.String[] {
- "Resource", "Permissions",
- });
- internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor =
- getDescriptor().getMessageTypes().get(3);
- internal_static_google_iam_v1_TestIamPermissionsResponse_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor,
- new java.lang.String[] {
- "Permissions",
- });
- com.google.protobuf.ExtensionRegistry registry =
- com.google.protobuf.ExtensionRegistry.newInstance();
- registry.add(com.google.api.ClientProto.defaultHost);
- registry.add(com.google.api.FieldBehaviorProto.fieldBehavior);
- registry.add(com.google.api.AnnotationsProto.http);
- registry.add(com.google.api.ResourceProto.resourceReference);
- com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor(
- descriptor, registry);
- com.google.api.AnnotationsProto.getDescriptor();
- com.google.api.ClientProto.getDescriptor();
- com.google.api.FieldBehaviorProto.getDescriptor();
- com.google.api.ResourceProto.getDescriptor();
- com.google.iam.v1.OptionsProto.getDescriptor();
- com.google.iam.v1.PolicyProto.getDescriptor();
- com.google.protobuf.FieldMaskProto.getDescriptor();
- }
-
- // @@protoc_insertion_point(outer_class_scope)
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/OptionsProto.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/OptionsProto.java
deleted file mode 100644
index 9c13280b..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/OptionsProto.java
+++ /dev/null
@@ -1,65 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/options.proto
-
-package com.google.iam.v1;
-
-public final class OptionsProto {
- private OptionsProto() {}
-
- public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {}
-
- public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) {
- registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry);
- }
-
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_GetPolicyOptions_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_GetPolicyOptions_fieldAccessorTable;
-
- public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
- return descriptor;
- }
-
- private static com.google.protobuf.Descriptors.FileDescriptor descriptor;
-
- static {
- java.lang.String[] descriptorData = {
- "\n\033google/iam/v1/options.proto\022\rgoogle.ia"
- + "m.v1\"4\n\020GetPolicyOptions\022 \n\030requested_po"
- + "licy_version\030\001 \001(\005B\204\001\n\021com.google.iam.v1"
- + "B\014OptionsProtoP\001Z0google.golang.org/genp"
- + "roto/googleapis/iam/v1;iam\370\001\001\252\002\023Google.C"
- + "loud.Iam.V1\312\002\023Google\\Cloud\\Iam\\V1b\006proto"
- + "3"
- };
- descriptor =
- com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom(
- descriptorData, new com.google.protobuf.Descriptors.FileDescriptor[] {});
- internal_static_google_iam_v1_GetPolicyOptions_descriptor =
- getDescriptor().getMessageTypes().get(0);
- internal_static_google_iam_v1_GetPolicyOptions_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_GetPolicyOptions_descriptor,
- new java.lang.String[] {
- "RequestedPolicyVersion",
- });
- }
-
- // @@protoc_insertion_point(outer_class_scope)
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/Policy.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/Policy.java
deleted file mode 100644
index b03aa80d..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/Policy.java
+++ /dev/null
@@ -1,1984 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/policy.proto
-
-package com.google.iam.v1;
-
-/**
- *
- *
- * - * An Identity and Access Management (IAM) policy, which specifies access - * controls for Google Cloud resources. - * A `Policy` is a collection of `bindings`. A `binding` binds one or more - * `members`, or principals, to a single `role`. Principals can be user - * accounts, service accounts, Google groups, and domains (such as G Suite). A - * `role` is a named list of permissions; each `role` can be an IAM predefined - * role or a user-created custom role. - * For some types of Google Cloud resources, a `binding` can also specify a - * `condition`, which is a logical expression that allows access to a resource - * only if the expression evaluates to `true`. A condition can add constraints - * based on attributes of the request, the resource, or both. To learn which - * resources support conditions in their IAM policies, see the - * [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - * **JSON example:** - * { - * "bindings": [ - * { - * "role": "roles/resourcemanager.organizationAdmin", - * "members": [ - * "user:mike@example.com", - * "group:admins@example.com", - * "domain:google.com", - * "serviceAccount:my-project-id@appspot.gserviceaccount.com" - * ] - * }, - * { - * "role": "roles/resourcemanager.organizationViewer", - * "members": [ - * "user:eve@example.com" - * ], - * "condition": { - * "title": "expirable access", - * "description": "Does not grant access after Sep 2020", - * "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", - * } - * } - * ], - * "etag": "BwWWja0YfJA=", - * "version": 3 - * } - * **YAML example:** - * bindings: - * - members: - * - user:mike@example.com - * - group:admins@example.com - * - domain:google.com - * - serviceAccount:my-project-id@appspot.gserviceaccount.com - * role: roles/resourcemanager.organizationAdmin - * - members: - * - user:eve@example.com - * role: roles/resourcemanager.organizationViewer - * condition: - * title: expirable access - * description: Does not grant access after Sep 2020 - * expression: request.time < timestamp('2020-10-01T00:00:00.000Z') - * etag: BwWWja0YfJA= - * version: 3 - * For a description of IAM and its features, see the - * [IAM documentation](https://cloud.google.com/iam/docs/). - *- * - * Protobuf type {@code google.iam.v1.Policy} - */ -public final class Policy extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.Policy) - PolicyOrBuilder { - private static final long serialVersionUID = 0L; - // Use Policy.newBuilder() to construct. - private Policy(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private Policy() { - bindings_ = java.util.Collections.emptyList(); - auditConfigs_ = java.util.Collections.emptyList(); - etag_ = com.google.protobuf.ByteString.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Policy(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Policy_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Policy_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.Policy.class, com.google.iam.v1.Policy.Builder.class); - } - - public static final int VERSION_FIELD_NUMBER = 1; - private int version_; - /** - * - * - *
- * Specifies the format of the policy. - * Valid values are `0`, `1`, and `3`. Requests that specify an invalid value - * are rejected. - * Any operation that affects conditional role bindings must specify version - * `3`. This requirement applies to the following operations: - * * Getting a policy that includes a conditional role binding - * * Adding a conditional role binding to a policy - * * Changing a conditional role binding in a policy - * * Removing any role binding, with or without a condition, from a policy - * that includes conditions - * **Important:** If you use IAM Conditions, you must include the `etag` field - * whenever you call `setIamPolicy`. If you omit this field, then IAM allows - * you to overwrite a version `3` policy with a version `1` policy, and all of - * the conditions in the version `3` policy are lost. - * If a policy does not include any conditions, operations on that policy may - * specify any valid version or leave the field unset. - * To learn which resources support conditions in their IAM policies, see the - * [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
int32 version = 1;
- *
- * @return The version.
- */
- @java.lang.Override
- public int getVersion() {
- return version_;
- }
-
- public static final int BINDINGS_FIELD_NUMBER = 4;
- private java.util.List- * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- @java.lang.Override
- public java.util.List- * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- @java.lang.Override
- public java.util.List extends com.google.iam.v1.BindingOrBuilder> getBindingsOrBuilderList() {
- return bindings_;
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- @java.lang.Override
- public int getBindingsCount() {
- return bindings_.size();
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- @java.lang.Override
- public com.google.iam.v1.Binding getBindings(int index) {
- return bindings_.get(index);
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- @java.lang.Override
- public com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(int index) {
- return bindings_.get(index);
- }
-
- public static final int AUDIT_CONFIGS_FIELD_NUMBER = 6;
- private java.util.List- * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- @java.lang.Override
- public java.util.List- * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- @java.lang.Override
- public java.util.List extends com.google.iam.v1.AuditConfigOrBuilder>
- getAuditConfigsOrBuilderList() {
- return auditConfigs_;
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- @java.lang.Override
- public int getAuditConfigsCount() {
- return auditConfigs_.size();
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- @java.lang.Override
- public com.google.iam.v1.AuditConfig getAuditConfigs(int index) {
- return auditConfigs_.get(index);
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- @java.lang.Override
- public com.google.iam.v1.AuditConfigOrBuilder getAuditConfigsOrBuilder(int index) {
- return auditConfigs_.get(index);
- }
-
- public static final int ETAG_FIELD_NUMBER = 3;
- private com.google.protobuf.ByteString etag_;
- /**
- *
- *
- * - * `etag` is used for optimistic concurrency control as a way to help - * prevent simultaneous updates of a policy from overwriting each other. - * It is strongly suggested that systems make use of the `etag` in the - * read-modify-write cycle to perform policy updates in order to avoid race - * conditions: An `etag` is returned in the response to `getIamPolicy`, and - * systems are expected to put that etag in the request to `setIamPolicy` to - * ensure that their change will be applied to the same version of the policy. - * **Important:** If you use IAM Conditions, you must include the `etag` field - * whenever you call `setIamPolicy`. If you omit this field, then IAM allows - * you to overwrite a version `3` policy with a version `1` policy, and all of - * the conditions in the version `3` policy are lost. - *- * - *
bytes etag = 3;
- *
- * @return The etag.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getEtag() {
- return etag_;
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (version_ != 0) {
- output.writeInt32(1, version_);
- }
- if (!etag_.isEmpty()) {
- output.writeBytes(3, etag_);
- }
- for (int i = 0; i < bindings_.size(); i++) {
- output.writeMessage(4, bindings_.get(i));
- }
- for (int i = 0; i < auditConfigs_.size(); i++) {
- output.writeMessage(6, auditConfigs_.get(i));
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (version_ != 0) {
- size += com.google.protobuf.CodedOutputStream.computeInt32Size(1, version_);
- }
- if (!etag_.isEmpty()) {
- size += com.google.protobuf.CodedOutputStream.computeBytesSize(3, etag_);
- }
- for (int i = 0; i < bindings_.size(); i++) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, bindings_.get(i));
- }
- for (int i = 0; i < auditConfigs_.size(); i++) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, auditConfigs_.get(i));
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.Policy)) {
- return super.equals(obj);
- }
- com.google.iam.v1.Policy other = (com.google.iam.v1.Policy) obj;
-
- if (getVersion() != other.getVersion()) return false;
- if (!getBindingsList().equals(other.getBindingsList())) return false;
- if (!getAuditConfigsList().equals(other.getAuditConfigsList())) return false;
- if (!getEtag().equals(other.getEtag())) return false;
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + VERSION_FIELD_NUMBER;
- hash = (53 * hash) + getVersion();
- if (getBindingsCount() > 0) {
- hash = (37 * hash) + BINDINGS_FIELD_NUMBER;
- hash = (53 * hash) + getBindingsList().hashCode();
- }
- if (getAuditConfigsCount() > 0) {
- hash = (37 * hash) + AUDIT_CONFIGS_FIELD_NUMBER;
- hash = (53 * hash) + getAuditConfigsList().hashCode();
- }
- hash = (37 * hash) + ETAG_FIELD_NUMBER;
- hash = (53 * hash) + getEtag().hashCode();
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.Policy parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.Policy parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.Policy parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.Policy parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.Policy parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.Policy parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.Policy parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.Policy parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.Policy parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.Policy parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.Policy parseFrom(com.google.protobuf.CodedInputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.Policy parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.Policy prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * An Identity and Access Management (IAM) policy, which specifies access - * controls for Google Cloud resources. - * A `Policy` is a collection of `bindings`. A `binding` binds one or more - * `members`, or principals, to a single `role`. Principals can be user - * accounts, service accounts, Google groups, and domains (such as G Suite). A - * `role` is a named list of permissions; each `role` can be an IAM predefined - * role or a user-created custom role. - * For some types of Google Cloud resources, a `binding` can also specify a - * `condition`, which is a logical expression that allows access to a resource - * only if the expression evaluates to `true`. A condition can add constraints - * based on attributes of the request, the resource, or both. To learn which - * resources support conditions in their IAM policies, see the - * [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - * **JSON example:** - * { - * "bindings": [ - * { - * "role": "roles/resourcemanager.organizationAdmin", - * "members": [ - * "user:mike@example.com", - * "group:admins@example.com", - * "domain:google.com", - * "serviceAccount:my-project-id@appspot.gserviceaccount.com" - * ] - * }, - * { - * "role": "roles/resourcemanager.organizationViewer", - * "members": [ - * "user:eve@example.com" - * ], - * "condition": { - * "title": "expirable access", - * "description": "Does not grant access after Sep 2020", - * "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", - * } - * } - * ], - * "etag": "BwWWja0YfJA=", - * "version": 3 - * } - * **YAML example:** - * bindings: - * - members: - * - user:mike@example.com - * - group:admins@example.com - * - domain:google.com - * - serviceAccount:my-project-id@appspot.gserviceaccount.com - * role: roles/resourcemanager.organizationAdmin - * - members: - * - user:eve@example.com - * role: roles/resourcemanager.organizationViewer - * condition: - * title: expirable access - * description: Does not grant access after Sep 2020 - * expression: request.time < timestamp('2020-10-01T00:00:00.000Z') - * etag: BwWWja0YfJA= - * version: 3 - * For a description of IAM and its features, see the - * [IAM documentation](https://cloud.google.com/iam/docs/). - *- * - * Protobuf type {@code google.iam.v1.Policy} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * Specifies the format of the policy. - * Valid values are `0`, `1`, and `3`. Requests that specify an invalid value - * are rejected. - * Any operation that affects conditional role bindings must specify version - * `3`. This requirement applies to the following operations: - * * Getting a policy that includes a conditional role binding - * * Adding a conditional role binding to a policy - * * Changing a conditional role binding in a policy - * * Removing any role binding, with or without a condition, from a policy - * that includes conditions - * **Important:** If you use IAM Conditions, you must include the `etag` field - * whenever you call `setIamPolicy`. If you omit this field, then IAM allows - * you to overwrite a version `3` policy with a version `1` policy, and all of - * the conditions in the version `3` policy are lost. - * If a policy does not include any conditions, operations on that policy may - * specify any valid version or leave the field unset. - * To learn which resources support conditions in their IAM policies, see the - * [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
int32 version = 1;
- *
- * @return The version.
- */
- @java.lang.Override
- public int getVersion() {
- return version_;
- }
- /**
- *
- *
- * - * Specifies the format of the policy. - * Valid values are `0`, `1`, and `3`. Requests that specify an invalid value - * are rejected. - * Any operation that affects conditional role bindings must specify version - * `3`. This requirement applies to the following operations: - * * Getting a policy that includes a conditional role binding - * * Adding a conditional role binding to a policy - * * Changing a conditional role binding in a policy - * * Removing any role binding, with or without a condition, from a policy - * that includes conditions - * **Important:** If you use IAM Conditions, you must include the `etag` field - * whenever you call `setIamPolicy`. If you omit this field, then IAM allows - * you to overwrite a version `3` policy with a version `1` policy, and all of - * the conditions in the version `3` policy are lost. - * If a policy does not include any conditions, operations on that policy may - * specify any valid version or leave the field unset. - * To learn which resources support conditions in their IAM policies, see the - * [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
int32 version = 1;
- *
- * @param value The version to set.
- * @return This builder for chaining.
- */
- public Builder setVersion(int value) {
-
- version_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies the format of the policy. - * Valid values are `0`, `1`, and `3`. Requests that specify an invalid value - * are rejected. - * Any operation that affects conditional role bindings must specify version - * `3`. This requirement applies to the following operations: - * * Getting a policy that includes a conditional role binding - * * Adding a conditional role binding to a policy - * * Changing a conditional role binding in a policy - * * Removing any role binding, with or without a condition, from a policy - * that includes conditions - * **Important:** If you use IAM Conditions, you must include the `etag` field - * whenever you call `setIamPolicy`. If you omit this field, then IAM allows - * you to overwrite a version `3` policy with a version `1` policy, and all of - * the conditions in the version `3` policy are lost. - * If a policy does not include any conditions, operations on that policy may - * specify any valid version or leave the field unset. - * To learn which resources support conditions in their IAM policies, see the - * [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
int32 version = 1;
- *
- * @return This builder for chaining.
- */
- public Builder clearVersion() {
-
- version_ = 0;
- onChanged();
- return this;
- }
-
- private java.util.List- * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public java.util.List- * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public int getBindingsCount() {
- if (bindingsBuilder_ == null) {
- return bindings_.size();
- } else {
- return bindingsBuilder_.getCount();
- }
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public com.google.iam.v1.Binding getBindings(int index) {
- if (bindingsBuilder_ == null) {
- return bindings_.get(index);
- } else {
- return bindingsBuilder_.getMessage(index);
- }
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public Builder setBindings(int index, com.google.iam.v1.Binding value) {
- if (bindingsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBindingsIsMutable();
- bindings_.set(index, value);
- onChanged();
- } else {
- bindingsBuilder_.setMessage(index, value);
- }
- return this;
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public Builder setBindings(int index, com.google.iam.v1.Binding.Builder builderForValue) {
- if (bindingsBuilder_ == null) {
- ensureBindingsIsMutable();
- bindings_.set(index, builderForValue.build());
- onChanged();
- } else {
- bindingsBuilder_.setMessage(index, builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public Builder addBindings(com.google.iam.v1.Binding value) {
- if (bindingsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBindingsIsMutable();
- bindings_.add(value);
- onChanged();
- } else {
- bindingsBuilder_.addMessage(value);
- }
- return this;
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public Builder addBindings(int index, com.google.iam.v1.Binding value) {
- if (bindingsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBindingsIsMutable();
- bindings_.add(index, value);
- onChanged();
- } else {
- bindingsBuilder_.addMessage(index, value);
- }
- return this;
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public Builder addBindings(com.google.iam.v1.Binding.Builder builderForValue) {
- if (bindingsBuilder_ == null) {
- ensureBindingsIsMutable();
- bindings_.add(builderForValue.build());
- onChanged();
- } else {
- bindingsBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public Builder addBindings(int index, com.google.iam.v1.Binding.Builder builderForValue) {
- if (bindingsBuilder_ == null) {
- ensureBindingsIsMutable();
- bindings_.add(index, builderForValue.build());
- onChanged();
- } else {
- bindingsBuilder_.addMessage(index, builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public Builder addAllBindings(java.lang.Iterable extends com.google.iam.v1.Binding> values) {
- if (bindingsBuilder_ == null) {
- ensureBindingsIsMutable();
- com.google.protobuf.AbstractMessageLite.Builder.addAll(values, bindings_);
- onChanged();
- } else {
- bindingsBuilder_.addAllMessages(values);
- }
- return this;
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public Builder clearBindings() {
- if (bindingsBuilder_ == null) {
- bindings_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000001);
- onChanged();
- } else {
- bindingsBuilder_.clear();
- }
- return this;
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public Builder removeBindings(int index) {
- if (bindingsBuilder_ == null) {
- ensureBindingsIsMutable();
- bindings_.remove(index);
- onChanged();
- } else {
- bindingsBuilder_.remove(index);
- }
- return this;
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public com.google.iam.v1.Binding.Builder getBindingsBuilder(int index) {
- return getBindingsFieldBuilder().getBuilder(index);
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(int index) {
- if (bindingsBuilder_ == null) {
- return bindings_.get(index);
- } else {
- return bindingsBuilder_.getMessageOrBuilder(index);
- }
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public java.util.List extends com.google.iam.v1.BindingOrBuilder> getBindingsOrBuilderList() {
- if (bindingsBuilder_ != null) {
- return bindingsBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(bindings_);
- }
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public com.google.iam.v1.Binding.Builder addBindingsBuilder() {
- return getBindingsFieldBuilder().addBuilder(com.google.iam.v1.Binding.getDefaultInstance());
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public com.google.iam.v1.Binding.Builder addBindingsBuilder(int index) {
- return getBindingsFieldBuilder()
- .addBuilder(index, com.google.iam.v1.Binding.getDefaultInstance());
- }
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- public java.util.List- * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public java.util.List- * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public int getAuditConfigsCount() {
- if (auditConfigsBuilder_ == null) {
- return auditConfigs_.size();
- } else {
- return auditConfigsBuilder_.getCount();
- }
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public com.google.iam.v1.AuditConfig getAuditConfigs(int index) {
- if (auditConfigsBuilder_ == null) {
- return auditConfigs_.get(index);
- } else {
- return auditConfigsBuilder_.getMessage(index);
- }
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public Builder setAuditConfigs(int index, com.google.iam.v1.AuditConfig value) {
- if (auditConfigsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAuditConfigsIsMutable();
- auditConfigs_.set(index, value);
- onChanged();
- } else {
- auditConfigsBuilder_.setMessage(index, value);
- }
- return this;
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public Builder setAuditConfigs(
- int index, com.google.iam.v1.AuditConfig.Builder builderForValue) {
- if (auditConfigsBuilder_ == null) {
- ensureAuditConfigsIsMutable();
- auditConfigs_.set(index, builderForValue.build());
- onChanged();
- } else {
- auditConfigsBuilder_.setMessage(index, builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public Builder addAuditConfigs(com.google.iam.v1.AuditConfig value) {
- if (auditConfigsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAuditConfigsIsMutable();
- auditConfigs_.add(value);
- onChanged();
- } else {
- auditConfigsBuilder_.addMessage(value);
- }
- return this;
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public Builder addAuditConfigs(int index, com.google.iam.v1.AuditConfig value) {
- if (auditConfigsBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAuditConfigsIsMutable();
- auditConfigs_.add(index, value);
- onChanged();
- } else {
- auditConfigsBuilder_.addMessage(index, value);
- }
- return this;
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public Builder addAuditConfigs(com.google.iam.v1.AuditConfig.Builder builderForValue) {
- if (auditConfigsBuilder_ == null) {
- ensureAuditConfigsIsMutable();
- auditConfigs_.add(builderForValue.build());
- onChanged();
- } else {
- auditConfigsBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public Builder addAuditConfigs(
- int index, com.google.iam.v1.AuditConfig.Builder builderForValue) {
- if (auditConfigsBuilder_ == null) {
- ensureAuditConfigsIsMutable();
- auditConfigs_.add(index, builderForValue.build());
- onChanged();
- } else {
- auditConfigsBuilder_.addMessage(index, builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public Builder addAllAuditConfigs(
- java.lang.Iterable extends com.google.iam.v1.AuditConfig> values) {
- if (auditConfigsBuilder_ == null) {
- ensureAuditConfigsIsMutable();
- com.google.protobuf.AbstractMessageLite.Builder.addAll(values, auditConfigs_);
- onChanged();
- } else {
- auditConfigsBuilder_.addAllMessages(values);
- }
- return this;
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public Builder clearAuditConfigs() {
- if (auditConfigsBuilder_ == null) {
- auditConfigs_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000002);
- onChanged();
- } else {
- auditConfigsBuilder_.clear();
- }
- return this;
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public Builder removeAuditConfigs(int index) {
- if (auditConfigsBuilder_ == null) {
- ensureAuditConfigsIsMutable();
- auditConfigs_.remove(index);
- onChanged();
- } else {
- auditConfigsBuilder_.remove(index);
- }
- return this;
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public com.google.iam.v1.AuditConfig.Builder getAuditConfigsBuilder(int index) {
- return getAuditConfigsFieldBuilder().getBuilder(index);
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public com.google.iam.v1.AuditConfigOrBuilder getAuditConfigsOrBuilder(int index) {
- if (auditConfigsBuilder_ == null) {
- return auditConfigs_.get(index);
- } else {
- return auditConfigsBuilder_.getMessageOrBuilder(index);
- }
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public java.util.List extends com.google.iam.v1.AuditConfigOrBuilder>
- getAuditConfigsOrBuilderList() {
- if (auditConfigsBuilder_ != null) {
- return auditConfigsBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(auditConfigs_);
- }
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public com.google.iam.v1.AuditConfig.Builder addAuditConfigsBuilder() {
- return getAuditConfigsFieldBuilder()
- .addBuilder(com.google.iam.v1.AuditConfig.getDefaultInstance());
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public com.google.iam.v1.AuditConfig.Builder addAuditConfigsBuilder(int index) {
- return getAuditConfigsFieldBuilder()
- .addBuilder(index, com.google.iam.v1.AuditConfig.getDefaultInstance());
- }
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- public java.util.List- * `etag` is used for optimistic concurrency control as a way to help - * prevent simultaneous updates of a policy from overwriting each other. - * It is strongly suggested that systems make use of the `etag` in the - * read-modify-write cycle to perform policy updates in order to avoid race - * conditions: An `etag` is returned in the response to `getIamPolicy`, and - * systems are expected to put that etag in the request to `setIamPolicy` to - * ensure that their change will be applied to the same version of the policy. - * **Important:** If you use IAM Conditions, you must include the `etag` field - * whenever you call `setIamPolicy`. If you omit this field, then IAM allows - * you to overwrite a version `3` policy with a version `1` policy, and all of - * the conditions in the version `3` policy are lost. - *- * - *
bytes etag = 3;
- *
- * @return The etag.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getEtag() {
- return etag_;
- }
- /**
- *
- *
- * - * `etag` is used for optimistic concurrency control as a way to help - * prevent simultaneous updates of a policy from overwriting each other. - * It is strongly suggested that systems make use of the `etag` in the - * read-modify-write cycle to perform policy updates in order to avoid race - * conditions: An `etag` is returned in the response to `getIamPolicy`, and - * systems are expected to put that etag in the request to `setIamPolicy` to - * ensure that their change will be applied to the same version of the policy. - * **Important:** If you use IAM Conditions, you must include the `etag` field - * whenever you call `setIamPolicy`. If you omit this field, then IAM allows - * you to overwrite a version `3` policy with a version `1` policy, and all of - * the conditions in the version `3` policy are lost. - *- * - *
bytes etag = 3;
- *
- * @param value The etag to set.
- * @return This builder for chaining.
- */
- public Builder setEtag(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- etag_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * `etag` is used for optimistic concurrency control as a way to help - * prevent simultaneous updates of a policy from overwriting each other. - * It is strongly suggested that systems make use of the `etag` in the - * read-modify-write cycle to perform policy updates in order to avoid race - * conditions: An `etag` is returned in the response to `getIamPolicy`, and - * systems are expected to put that etag in the request to `setIamPolicy` to - * ensure that their change will be applied to the same version of the policy. - * **Important:** If you use IAM Conditions, you must include the `etag` field - * whenever you call `setIamPolicy`. If you omit this field, then IAM allows - * you to overwrite a version `3` policy with a version `1` policy, and all of - * the conditions in the version `3` policy are lost. - *- * - *
bytes etag = 3;
- *
- * @return This builder for chaining.
- */
- public Builder clearEtag() {
-
- etag_ = getDefaultInstance().getEtag();
- onChanged();
- return this;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v1.Policy)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v1.Policy)
- private static final com.google.iam.v1.Policy DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v1.Policy();
- }
-
- public static com.google.iam.v1.Policy getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * The difference delta between two policies. - *- * - * Protobuf type {@code google.iam.v1.PolicyDelta} - */ -public final class PolicyDelta extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.PolicyDelta) - PolicyDeltaOrBuilder { - private static final long serialVersionUID = 0L; - // Use PolicyDelta.newBuilder() to construct. - private PolicyDelta(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private PolicyDelta() { - bindingDeltas_ = java.util.Collections.emptyList(); - auditConfigDeltas_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new PolicyDelta(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_PolicyDelta_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.PolicyProto - .internal_static_google_iam_v1_PolicyDelta_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.PolicyDelta.class, com.google.iam.v1.PolicyDelta.Builder.class); - } - - public static final int BINDING_DELTAS_FIELD_NUMBER = 1; - private java.util.List
- * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- @java.lang.Override
- public java.util.List- * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- @java.lang.Override
- public java.util.List extends com.google.iam.v1.BindingDeltaOrBuilder>
- getBindingDeltasOrBuilderList() {
- return bindingDeltas_;
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- @java.lang.Override
- public int getBindingDeltasCount() {
- return bindingDeltas_.size();
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- @java.lang.Override
- public com.google.iam.v1.BindingDelta getBindingDeltas(int index) {
- return bindingDeltas_.get(index);
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- @java.lang.Override
- public com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder(int index) {
- return bindingDeltas_.get(index);
- }
-
- public static final int AUDIT_CONFIG_DELTAS_FIELD_NUMBER = 2;
- private java.util.List- * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- @java.lang.Override
- public java.util.List- * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- @java.lang.Override
- public java.util.List extends com.google.iam.v1.AuditConfigDeltaOrBuilder>
- getAuditConfigDeltasOrBuilderList() {
- return auditConfigDeltas_;
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- @java.lang.Override
- public int getAuditConfigDeltasCount() {
- return auditConfigDeltas_.size();
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- @java.lang.Override
- public com.google.iam.v1.AuditConfigDelta getAuditConfigDeltas(int index) {
- return auditConfigDeltas_.get(index);
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- @java.lang.Override
- public com.google.iam.v1.AuditConfigDeltaOrBuilder getAuditConfigDeltasOrBuilder(int index) {
- return auditConfigDeltas_.get(index);
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- for (int i = 0; i < bindingDeltas_.size(); i++) {
- output.writeMessage(1, bindingDeltas_.get(i));
- }
- for (int i = 0; i < auditConfigDeltas_.size(); i++) {
- output.writeMessage(2, auditConfigDeltas_.get(i));
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- for (int i = 0; i < bindingDeltas_.size(); i++) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, bindingDeltas_.get(i));
- }
- for (int i = 0; i < auditConfigDeltas_.size(); i++) {
- size +=
- com.google.protobuf.CodedOutputStream.computeMessageSize(2, auditConfigDeltas_.get(i));
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.PolicyDelta)) {
- return super.equals(obj);
- }
- com.google.iam.v1.PolicyDelta other = (com.google.iam.v1.PolicyDelta) obj;
-
- if (!getBindingDeltasList().equals(other.getBindingDeltasList())) return false;
- if (!getAuditConfigDeltasList().equals(other.getAuditConfigDeltasList())) return false;
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- if (getBindingDeltasCount() > 0) {
- hash = (37 * hash) + BINDING_DELTAS_FIELD_NUMBER;
- hash = (53 * hash) + getBindingDeltasList().hashCode();
- }
- if (getAuditConfigDeltasCount() > 0) {
- hash = (37 * hash) + AUDIT_CONFIG_DELTAS_FIELD_NUMBER;
- hash = (53 * hash) + getAuditConfigDeltasList().hashCode();
- }
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.PolicyDelta parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.PolicyDelta parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.PolicyDelta parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.PolicyDelta parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.PolicyDelta parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.PolicyDelta parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.PolicyDelta parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.PolicyDelta parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.PolicyDelta parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.PolicyDelta parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.PolicyDelta parseFrom(com.google.protobuf.CodedInputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.PolicyDelta parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.PolicyDelta prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * The difference delta between two policies. - *- * - * Protobuf type {@code google.iam.v1.PolicyDelta} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public java.util.List- * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public int getBindingDeltasCount() {
- if (bindingDeltasBuilder_ == null) {
- return bindingDeltas_.size();
- } else {
- return bindingDeltasBuilder_.getCount();
- }
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public com.google.iam.v1.BindingDelta getBindingDeltas(int index) {
- if (bindingDeltasBuilder_ == null) {
- return bindingDeltas_.get(index);
- } else {
- return bindingDeltasBuilder_.getMessage(index);
- }
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public Builder setBindingDeltas(int index, com.google.iam.v1.BindingDelta value) {
- if (bindingDeltasBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBindingDeltasIsMutable();
- bindingDeltas_.set(index, value);
- onChanged();
- } else {
- bindingDeltasBuilder_.setMessage(index, value);
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public Builder setBindingDeltas(
- int index, com.google.iam.v1.BindingDelta.Builder builderForValue) {
- if (bindingDeltasBuilder_ == null) {
- ensureBindingDeltasIsMutable();
- bindingDeltas_.set(index, builderForValue.build());
- onChanged();
- } else {
- bindingDeltasBuilder_.setMessage(index, builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public Builder addBindingDeltas(com.google.iam.v1.BindingDelta value) {
- if (bindingDeltasBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBindingDeltasIsMutable();
- bindingDeltas_.add(value);
- onChanged();
- } else {
- bindingDeltasBuilder_.addMessage(value);
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public Builder addBindingDeltas(int index, com.google.iam.v1.BindingDelta value) {
- if (bindingDeltasBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureBindingDeltasIsMutable();
- bindingDeltas_.add(index, value);
- onChanged();
- } else {
- bindingDeltasBuilder_.addMessage(index, value);
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public Builder addBindingDeltas(com.google.iam.v1.BindingDelta.Builder builderForValue) {
- if (bindingDeltasBuilder_ == null) {
- ensureBindingDeltasIsMutable();
- bindingDeltas_.add(builderForValue.build());
- onChanged();
- } else {
- bindingDeltasBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public Builder addBindingDeltas(
- int index, com.google.iam.v1.BindingDelta.Builder builderForValue) {
- if (bindingDeltasBuilder_ == null) {
- ensureBindingDeltasIsMutable();
- bindingDeltas_.add(index, builderForValue.build());
- onChanged();
- } else {
- bindingDeltasBuilder_.addMessage(index, builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public Builder addAllBindingDeltas(
- java.lang.Iterable extends com.google.iam.v1.BindingDelta> values) {
- if (bindingDeltasBuilder_ == null) {
- ensureBindingDeltasIsMutable();
- com.google.protobuf.AbstractMessageLite.Builder.addAll(values, bindingDeltas_);
- onChanged();
- } else {
- bindingDeltasBuilder_.addAllMessages(values);
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public Builder clearBindingDeltas() {
- if (bindingDeltasBuilder_ == null) {
- bindingDeltas_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000001);
- onChanged();
- } else {
- bindingDeltasBuilder_.clear();
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public Builder removeBindingDeltas(int index) {
- if (bindingDeltasBuilder_ == null) {
- ensureBindingDeltasIsMutable();
- bindingDeltas_.remove(index);
- onChanged();
- } else {
- bindingDeltasBuilder_.remove(index);
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public com.google.iam.v1.BindingDelta.Builder getBindingDeltasBuilder(int index) {
- return getBindingDeltasFieldBuilder().getBuilder(index);
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder(int index) {
- if (bindingDeltasBuilder_ == null) {
- return bindingDeltas_.get(index);
- } else {
- return bindingDeltasBuilder_.getMessageOrBuilder(index);
- }
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public java.util.List extends com.google.iam.v1.BindingDeltaOrBuilder>
- getBindingDeltasOrBuilderList() {
- if (bindingDeltasBuilder_ != null) {
- return bindingDeltasBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(bindingDeltas_);
- }
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public com.google.iam.v1.BindingDelta.Builder addBindingDeltasBuilder() {
- return getBindingDeltasFieldBuilder()
- .addBuilder(com.google.iam.v1.BindingDelta.getDefaultInstance());
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public com.google.iam.v1.BindingDelta.Builder addBindingDeltasBuilder(int index) {
- return getBindingDeltasFieldBuilder()
- .addBuilder(index, com.google.iam.v1.BindingDelta.getDefaultInstance());
- }
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- public java.util.List- * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public java.util.List- * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public int getAuditConfigDeltasCount() {
- if (auditConfigDeltasBuilder_ == null) {
- return auditConfigDeltas_.size();
- } else {
- return auditConfigDeltasBuilder_.getCount();
- }
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public com.google.iam.v1.AuditConfigDelta getAuditConfigDeltas(int index) {
- if (auditConfigDeltasBuilder_ == null) {
- return auditConfigDeltas_.get(index);
- } else {
- return auditConfigDeltasBuilder_.getMessage(index);
- }
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public Builder setAuditConfigDeltas(int index, com.google.iam.v1.AuditConfigDelta value) {
- if (auditConfigDeltasBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAuditConfigDeltasIsMutable();
- auditConfigDeltas_.set(index, value);
- onChanged();
- } else {
- auditConfigDeltasBuilder_.setMessage(index, value);
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public Builder setAuditConfigDeltas(
- int index, com.google.iam.v1.AuditConfigDelta.Builder builderForValue) {
- if (auditConfigDeltasBuilder_ == null) {
- ensureAuditConfigDeltasIsMutable();
- auditConfigDeltas_.set(index, builderForValue.build());
- onChanged();
- } else {
- auditConfigDeltasBuilder_.setMessage(index, builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public Builder addAuditConfigDeltas(com.google.iam.v1.AuditConfigDelta value) {
- if (auditConfigDeltasBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAuditConfigDeltasIsMutable();
- auditConfigDeltas_.add(value);
- onChanged();
- } else {
- auditConfigDeltasBuilder_.addMessage(value);
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public Builder addAuditConfigDeltas(int index, com.google.iam.v1.AuditConfigDelta value) {
- if (auditConfigDeltasBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureAuditConfigDeltasIsMutable();
- auditConfigDeltas_.add(index, value);
- onChanged();
- } else {
- auditConfigDeltasBuilder_.addMessage(index, value);
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public Builder addAuditConfigDeltas(
- com.google.iam.v1.AuditConfigDelta.Builder builderForValue) {
- if (auditConfigDeltasBuilder_ == null) {
- ensureAuditConfigDeltasIsMutable();
- auditConfigDeltas_.add(builderForValue.build());
- onChanged();
- } else {
- auditConfigDeltasBuilder_.addMessage(builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public Builder addAuditConfigDeltas(
- int index, com.google.iam.v1.AuditConfigDelta.Builder builderForValue) {
- if (auditConfigDeltasBuilder_ == null) {
- ensureAuditConfigDeltasIsMutable();
- auditConfigDeltas_.add(index, builderForValue.build());
- onChanged();
- } else {
- auditConfigDeltasBuilder_.addMessage(index, builderForValue.build());
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public Builder addAllAuditConfigDeltas(
- java.lang.Iterable extends com.google.iam.v1.AuditConfigDelta> values) {
- if (auditConfigDeltasBuilder_ == null) {
- ensureAuditConfigDeltasIsMutable();
- com.google.protobuf.AbstractMessageLite.Builder.addAll(values, auditConfigDeltas_);
- onChanged();
- } else {
- auditConfigDeltasBuilder_.addAllMessages(values);
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public Builder clearAuditConfigDeltas() {
- if (auditConfigDeltasBuilder_ == null) {
- auditConfigDeltas_ = java.util.Collections.emptyList();
- bitField0_ = (bitField0_ & ~0x00000002);
- onChanged();
- } else {
- auditConfigDeltasBuilder_.clear();
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public Builder removeAuditConfigDeltas(int index) {
- if (auditConfigDeltasBuilder_ == null) {
- ensureAuditConfigDeltasIsMutable();
- auditConfigDeltas_.remove(index);
- onChanged();
- } else {
- auditConfigDeltasBuilder_.remove(index);
- }
- return this;
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public com.google.iam.v1.AuditConfigDelta.Builder getAuditConfigDeltasBuilder(int index) {
- return getAuditConfigDeltasFieldBuilder().getBuilder(index);
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public com.google.iam.v1.AuditConfigDeltaOrBuilder getAuditConfigDeltasOrBuilder(int index) {
- if (auditConfigDeltasBuilder_ == null) {
- return auditConfigDeltas_.get(index);
- } else {
- return auditConfigDeltasBuilder_.getMessageOrBuilder(index);
- }
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public java.util.List extends com.google.iam.v1.AuditConfigDeltaOrBuilder>
- getAuditConfigDeltasOrBuilderList() {
- if (auditConfigDeltasBuilder_ != null) {
- return auditConfigDeltasBuilder_.getMessageOrBuilderList();
- } else {
- return java.util.Collections.unmodifiableList(auditConfigDeltas_);
- }
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public com.google.iam.v1.AuditConfigDelta.Builder addAuditConfigDeltasBuilder() {
- return getAuditConfigDeltasFieldBuilder()
- .addBuilder(com.google.iam.v1.AuditConfigDelta.getDefaultInstance());
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public com.google.iam.v1.AuditConfigDelta.Builder addAuditConfigDeltasBuilder(int index) {
- return getAuditConfigDeltasFieldBuilder()
- .addBuilder(index, com.google.iam.v1.AuditConfigDelta.getDefaultInstance());
- }
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- public java.util.List- * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- java.util.List- * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- com.google.iam.v1.BindingDelta getBindingDeltas(int index);
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- int getBindingDeltasCount();
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- java.util.List extends com.google.iam.v1.BindingDeltaOrBuilder> getBindingDeltasOrBuilderList();
- /**
- *
- *
- * - * The delta for Bindings between two policies. - *- * - *
repeated .google.iam.v1.BindingDelta binding_deltas = 1;
- */
- com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder(int index);
-
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- java.util.List- * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- com.google.iam.v1.AuditConfigDelta getAuditConfigDeltas(int index);
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- int getAuditConfigDeltasCount();
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- java.util.List extends com.google.iam.v1.AuditConfigDeltaOrBuilder>
- getAuditConfigDeltasOrBuilderList();
- /**
- *
- *
- * - * The delta for AuditConfigs between two policies. - *- * - *
repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2;
- */
- com.google.iam.v1.AuditConfigDeltaOrBuilder getAuditConfigDeltasOrBuilder(int index);
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyOrBuilder.java
deleted file mode 100644
index 571dcb80..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyOrBuilder.java
+++ /dev/null
@@ -1,220 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/policy.proto
-
-package com.google.iam.v1;
-
-public interface PolicyOrBuilder
- extends
- // @@protoc_insertion_point(interface_extends:google.iam.v1.Policy)
- com.google.protobuf.MessageOrBuilder {
-
- /**
- *
- *
- * - * Specifies the format of the policy. - * Valid values are `0`, `1`, and `3`. Requests that specify an invalid value - * are rejected. - * Any operation that affects conditional role bindings must specify version - * `3`. This requirement applies to the following operations: - * * Getting a policy that includes a conditional role binding - * * Adding a conditional role binding to a policy - * * Changing a conditional role binding in a policy - * * Removing any role binding, with or without a condition, from a policy - * that includes conditions - * **Important:** If you use IAM Conditions, you must include the `etag` field - * whenever you call `setIamPolicy`. If you omit this field, then IAM allows - * you to overwrite a version `3` policy with a version `1` policy, and all of - * the conditions in the version `3` policy are lost. - * If a policy does not include any conditions, operations on that policy may - * specify any valid version or leave the field unset. - * To learn which resources support conditions in their IAM policies, see the - * [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). - *- * - *
int32 version = 1;
- *
- * @return The version.
- */
- int getVersion();
-
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- java.util.List- * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- com.google.iam.v1.Binding getBindings(int index);
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- int getBindingsCount();
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- java.util.List extends com.google.iam.v1.BindingOrBuilder> getBindingsOrBuilderList();
- /**
- *
- *
- * - * Associates a list of `members`, or principals, with a `role`. Optionally, - * may specify a `condition` that determines how and when the `bindings` are - * applied. Each of the `bindings` must contain at least one principal. - * The `bindings` in a `Policy` can refer to up to 1,500 principals; up to 250 - * of these principals can be Google groups. Each occurrence of a principal - * counts towards these limits. For example, if the `bindings` grant 50 - * different roles to `user:alice@example.com`, and not to any other - * principal, then you can add another 1,450 principals to the `bindings` in - * the `Policy`. - *- * - *
repeated .google.iam.v1.Binding bindings = 4;
- */
- com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(int index);
-
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- java.util.List- * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- com.google.iam.v1.AuditConfig getAuditConfigs(int index);
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- int getAuditConfigsCount();
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- java.util.List extends com.google.iam.v1.AuditConfigOrBuilder> getAuditConfigsOrBuilderList();
- /**
- *
- *
- * - * Specifies cloud audit logging configuration for this policy. - *- * - *
repeated .google.iam.v1.AuditConfig audit_configs = 6;
- */
- com.google.iam.v1.AuditConfigOrBuilder getAuditConfigsOrBuilder(int index);
-
- /**
- *
- *
- * - * `etag` is used for optimistic concurrency control as a way to help - * prevent simultaneous updates of a policy from overwriting each other. - * It is strongly suggested that systems make use of the `etag` in the - * read-modify-write cycle to perform policy updates in order to avoid race - * conditions: An `etag` is returned in the response to `getIamPolicy`, and - * systems are expected to put that etag in the request to `setIamPolicy` to - * ensure that their change will be applied to the same version of the policy. - * **Important:** If you use IAM Conditions, you must include the `etag` field - * whenever you call `setIamPolicy`. If you omit this field, then IAM allows - * you to overwrite a version `3` policy with a version `1` policy, and all of - * the conditions in the version `3` policy are lost. - *- * - *
bytes etag = 3;
- *
- * @return The etag.
- */
- com.google.protobuf.ByteString getEtag();
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyProto.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyProto.java
deleted file mode 100644
index 8ba3e50a..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyProto.java
+++ /dev/null
@@ -1,161 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/policy.proto
-
-package com.google.iam.v1;
-
-public final class PolicyProto {
- private PolicyProto() {}
-
- public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {}
-
- public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) {
- registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry);
- }
-
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_Policy_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_Policy_fieldAccessorTable;
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_Binding_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_Binding_fieldAccessorTable;
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_AuditConfig_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_AuditConfig_fieldAccessorTable;
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_AuditLogConfig_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_AuditLogConfig_fieldAccessorTable;
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_PolicyDelta_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_PolicyDelta_fieldAccessorTable;
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_BindingDelta_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_BindingDelta_fieldAccessorTable;
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_AuditConfigDelta_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_AuditConfigDelta_fieldAccessorTable;
-
- public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
- return descriptor;
- }
-
- private static com.google.protobuf.Descriptors.FileDescriptor descriptor;
-
- static {
- java.lang.String[] descriptorData = {
- "\n\032google/iam/v1/policy.proto\022\rgoogle.iam"
- + ".v1\032\026google/type/expr.proto\"\204\001\n\006Policy\022\017"
- + "\n\007version\030\001 \001(\005\022(\n\010bindings\030\004 \003(\0132\026.goog"
- + "le.iam.v1.Binding\0221\n\raudit_configs\030\006 \003(\013"
- + "2\032.google.iam.v1.AuditConfig\022\014\n\004etag\030\003 \001"
- + "(\014\"N\n\007Binding\022\014\n\004role\030\001 \001(\t\022\017\n\007members\030\002"
- + " \003(\t\022$\n\tcondition\030\003 \001(\0132\021.google.type.Ex"
- + "pr\"X\n\013AuditConfig\022\017\n\007service\030\001 \001(\t\0228\n\021au"
- + "dit_log_configs\030\003 \003(\0132\035.google.iam.v1.Au"
- + "ditLogConfig\"\267\001\n\016AuditLogConfig\0227\n\010log_t"
- + "ype\030\001 \001(\0162%.google.iam.v1.AuditLogConfig"
- + ".LogType\022\030\n\020exempted_members\030\002 \003(\t\"R\n\007Lo"
- + "gType\022\030\n\024LOG_TYPE_UNSPECIFIED\020\000\022\016\n\nADMIN"
- + "_READ\020\001\022\016\n\nDATA_WRITE\020\002\022\r\n\tDATA_READ\020\003\"\200"
- + "\001\n\013PolicyDelta\0223\n\016binding_deltas\030\001 \003(\0132\033"
- + ".google.iam.v1.BindingDelta\022<\n\023audit_con"
- + "fig_deltas\030\002 \003(\0132\037.google.iam.v1.AuditCo"
- + "nfigDelta\"\275\001\n\014BindingDelta\0222\n\006action\030\001 \001"
- + "(\0162\".google.iam.v1.BindingDelta.Action\022\014"
- + "\n\004role\030\002 \001(\t\022\016\n\006member\030\003 \001(\t\022$\n\tconditio"
- + "n\030\004 \001(\0132\021.google.type.Expr\"5\n\006Action\022\026\n\022"
- + "ACTION_UNSPECIFIED\020\000\022\007\n\003ADD\020\001\022\n\n\006REMOVE\020"
- + "\002\"\275\001\n\020AuditConfigDelta\0226\n\006action\030\001 \001(\0162&"
- + ".google.iam.v1.AuditConfigDelta.Action\022\017"
- + "\n\007service\030\002 \001(\t\022\027\n\017exempted_member\030\003 \001(\t"
- + "\022\020\n\010log_type\030\004 \001(\t\"5\n\006Action\022\026\n\022ACTION_U"
- + "NSPECIFIED\020\000\022\007\n\003ADD\020\001\022\n\n\006REMOVE\020\002B\203\001\n\021co"
- + "m.google.iam.v1B\013PolicyProtoP\001Z0google.g"
- + "olang.org/genproto/googleapis/iam/v1;iam"
- + "\370\001\001\252\002\023Google.Cloud.Iam.V1\312\002\023Google\\Cloud"
- + "\\Iam\\V1b\006proto3"
- };
- descriptor =
- com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom(
- descriptorData,
- new com.google.protobuf.Descriptors.FileDescriptor[] {
- com.google.type.ExprProto.getDescriptor(),
- });
- internal_static_google_iam_v1_Policy_descriptor = getDescriptor().getMessageTypes().get(0);
- internal_static_google_iam_v1_Policy_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_Policy_descriptor,
- new java.lang.String[] {
- "Version", "Bindings", "AuditConfigs", "Etag",
- });
- internal_static_google_iam_v1_Binding_descriptor = getDescriptor().getMessageTypes().get(1);
- internal_static_google_iam_v1_Binding_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_Binding_descriptor,
- new java.lang.String[] {
- "Role", "Members", "Condition",
- });
- internal_static_google_iam_v1_AuditConfig_descriptor = getDescriptor().getMessageTypes().get(2);
- internal_static_google_iam_v1_AuditConfig_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_AuditConfig_descriptor,
- new java.lang.String[] {
- "Service", "AuditLogConfigs",
- });
- internal_static_google_iam_v1_AuditLogConfig_descriptor =
- getDescriptor().getMessageTypes().get(3);
- internal_static_google_iam_v1_AuditLogConfig_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_AuditLogConfig_descriptor,
- new java.lang.String[] {
- "LogType", "ExemptedMembers",
- });
- internal_static_google_iam_v1_PolicyDelta_descriptor = getDescriptor().getMessageTypes().get(4);
- internal_static_google_iam_v1_PolicyDelta_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_PolicyDelta_descriptor,
- new java.lang.String[] {
- "BindingDeltas", "AuditConfigDeltas",
- });
- internal_static_google_iam_v1_BindingDelta_descriptor =
- getDescriptor().getMessageTypes().get(5);
- internal_static_google_iam_v1_BindingDelta_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_BindingDelta_descriptor,
- new java.lang.String[] {
- "Action", "Role", "Member", "Condition",
- });
- internal_static_google_iam_v1_AuditConfigDelta_descriptor =
- getDescriptor().getMessageTypes().get(6);
- internal_static_google_iam_v1_AuditConfigDelta_fieldAccessorTable =
- new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
- internal_static_google_iam_v1_AuditConfigDelta_descriptor,
- new java.lang.String[] {
- "Action", "Service", "ExemptedMember", "LogType",
- });
- com.google.type.ExprProto.getDescriptor();
- }
-
- // @@protoc_insertion_point(outer_class_scope)
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/SetIamPolicyRequest.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/SetIamPolicyRequest.java
deleted file mode 100644
index 78d0c7aa..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/SetIamPolicyRequest.java
+++ /dev/null
@@ -1,1225 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/iam_policy.proto
-
-package com.google.iam.v1;
-
-/**
- *
- *
- * - * Request message for `SetIamPolicy` method. - *- * - * Protobuf type {@code google.iam.v1.SetIamPolicyRequest} - */ -public final class SetIamPolicyRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.SetIamPolicyRequest) - SetIamPolicyRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use SetIamPolicyRequest.newBuilder() to construct. - private SetIamPolicyRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private SetIamPolicyRequest() { - resource_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new SetIamPolicyRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.IamPolicyProto - .internal_static_google_iam_v1_SetIamPolicyRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.IamPolicyProto - .internal_static_google_iam_v1_SetIamPolicyRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.SetIamPolicyRequest.class, - com.google.iam.v1.SetIamPolicyRequest.Builder.class); - } - - public static final int RESOURCE_FIELD_NUMBER = 1; - private volatile java.lang.Object resource_; - /** - * - * - *
- * REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The resource.
- */
- @java.lang.Override
- public java.lang.String getResource() {
- java.lang.Object ref = resource_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- resource_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The bytes for resource.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getResourceBytes() {
- java.lang.Object ref = resource_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- resource_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- public static final int POLICY_FIELD_NUMBER = 2;
- private com.google.iam.v1.Policy policy_;
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return Whether the policy field is set.
- */
- @java.lang.Override
- public boolean hasPolicy() {
- return policy_ != null;
- }
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The policy.
- */
- @java.lang.Override
- public com.google.iam.v1.Policy getPolicy() {
- return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_;
- }
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- @java.lang.Override
- public com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder() {
- return getPolicy();
- }
-
- public static final int UPDATE_MASK_FIELD_NUMBER = 3;
- private com.google.protobuf.FieldMask updateMask_;
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- *
- * @return Whether the updateMask field is set.
- */
- @java.lang.Override
- public boolean hasUpdateMask() {
- return updateMask_ != null;
- }
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- *
- * @return The updateMask.
- */
- @java.lang.Override
- public com.google.protobuf.FieldMask getUpdateMask() {
- return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_;
- }
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- */
- @java.lang.Override
- public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() {
- return getUpdateMask();
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resource_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resource_);
- }
- if (policy_ != null) {
- output.writeMessage(2, getPolicy());
- }
- if (updateMask_ != null) {
- output.writeMessage(3, getUpdateMask());
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resource_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, resource_);
- }
- if (policy_ != null) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getPolicy());
- }
- if (updateMask_ != null) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getUpdateMask());
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.SetIamPolicyRequest)) {
- return super.equals(obj);
- }
- com.google.iam.v1.SetIamPolicyRequest other = (com.google.iam.v1.SetIamPolicyRequest) obj;
-
- if (!getResource().equals(other.getResource())) return false;
- if (hasPolicy() != other.hasPolicy()) return false;
- if (hasPolicy()) {
- if (!getPolicy().equals(other.getPolicy())) return false;
- }
- if (hasUpdateMask() != other.hasUpdateMask()) return false;
- if (hasUpdateMask()) {
- if (!getUpdateMask().equals(other.getUpdateMask())) return false;
- }
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + RESOURCE_FIELD_NUMBER;
- hash = (53 * hash) + getResource().hashCode();
- if (hasPolicy()) {
- hash = (37 * hash) + POLICY_FIELD_NUMBER;
- hash = (53 * hash) + getPolicy().hashCode();
- }
- if (hasUpdateMask()) {
- hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER;
- hash = (53 * hash) + getUpdateMask().hashCode();
- }
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseFrom(
- com.google.protobuf.CodedInputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.SetIamPolicyRequest prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * Request message for `SetIamPolicy` method. - *- * - * Protobuf type {@code google.iam.v1.SetIamPolicyRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The resource.
- */
- public java.lang.String getResource() {
- java.lang.Object ref = resource_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- resource_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The bytes for resource.
- */
- public com.google.protobuf.ByteString getResourceBytes() {
- java.lang.Object ref = resource_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- resource_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @param value The resource to set.
- * @return This builder for chaining.
- */
- public Builder setResource(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- resource_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return This builder for chaining.
- */
- public Builder clearResource() {
-
- resource_ = getDefaultInstance().getResource();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @param value The bytes for resource to set.
- * @return This builder for chaining.
- */
- public Builder setResourceBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- resource_ = value;
- onChanged();
- return this;
- }
-
- private com.google.iam.v1.Policy policy_;
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.iam.v1.Policy,
- com.google.iam.v1.Policy.Builder,
- com.google.iam.v1.PolicyOrBuilder>
- policyBuilder_;
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return Whether the policy field is set.
- */
- public boolean hasPolicy() {
- return policyBuilder_ != null || policy_ != null;
- }
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The policy.
- */
- public com.google.iam.v1.Policy getPolicy() {
- if (policyBuilder_ == null) {
- return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_;
- } else {
- return policyBuilder_.getMessage();
- }
- }
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public Builder setPolicy(com.google.iam.v1.Policy value) {
- if (policyBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- policy_ = value;
- onChanged();
- } else {
- policyBuilder_.setMessage(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public Builder setPolicy(com.google.iam.v1.Policy.Builder builderForValue) {
- if (policyBuilder_ == null) {
- policy_ = builderForValue.build();
- onChanged();
- } else {
- policyBuilder_.setMessage(builderForValue.build());
- }
-
- return this;
- }
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public Builder mergePolicy(com.google.iam.v1.Policy value) {
- if (policyBuilder_ == null) {
- if (policy_ != null) {
- policy_ = com.google.iam.v1.Policy.newBuilder(policy_).mergeFrom(value).buildPartial();
- } else {
- policy_ = value;
- }
- onChanged();
- } else {
- policyBuilder_.mergeFrom(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public Builder clearPolicy() {
- if (policyBuilder_ == null) {
- policy_ = null;
- onChanged();
- } else {
- policy_ = null;
- policyBuilder_ = null;
- }
-
- return this;
- }
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public com.google.iam.v1.Policy.Builder getPolicyBuilder() {
-
- onChanged();
- return getPolicyFieldBuilder().getBuilder();
- }
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder() {
- if (policyBuilder_ != null) {
- return policyBuilder_.getMessageOrBuilder();
- } else {
- return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_;
- }
- }
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.iam.v1.Policy,
- com.google.iam.v1.Policy.Builder,
- com.google.iam.v1.PolicyOrBuilder>
- getPolicyFieldBuilder() {
- if (policyBuilder_ == null) {
- policyBuilder_ =
- new com.google.protobuf.SingleFieldBuilderV3<
- com.google.iam.v1.Policy,
- com.google.iam.v1.Policy.Builder,
- com.google.iam.v1.PolicyOrBuilder>(getPolicy(), getParentForChildren(), isClean());
- policy_ = null;
- }
- return policyBuilder_;
- }
-
- private com.google.protobuf.FieldMask updateMask_;
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.protobuf.FieldMask,
- com.google.protobuf.FieldMask.Builder,
- com.google.protobuf.FieldMaskOrBuilder>
- updateMaskBuilder_;
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- *
- * @return Whether the updateMask field is set.
- */
- public boolean hasUpdateMask() {
- return updateMaskBuilder_ != null || updateMask_ != null;
- }
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- *
- * @return The updateMask.
- */
- public com.google.protobuf.FieldMask getUpdateMask() {
- if (updateMaskBuilder_ == null) {
- return updateMask_ == null
- ? com.google.protobuf.FieldMask.getDefaultInstance()
- : updateMask_;
- } else {
- return updateMaskBuilder_.getMessage();
- }
- }
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- */
- public Builder setUpdateMask(com.google.protobuf.FieldMask value) {
- if (updateMaskBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- updateMask_ = value;
- onChanged();
- } else {
- updateMaskBuilder_.setMessage(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- */
- public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) {
- if (updateMaskBuilder_ == null) {
- updateMask_ = builderForValue.build();
- onChanged();
- } else {
- updateMaskBuilder_.setMessage(builderForValue.build());
- }
-
- return this;
- }
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- */
- public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) {
- if (updateMaskBuilder_ == null) {
- if (updateMask_ != null) {
- updateMask_ =
- com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial();
- } else {
- updateMask_ = value;
- }
- onChanged();
- } else {
- updateMaskBuilder_.mergeFrom(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- */
- public Builder clearUpdateMask() {
- if (updateMaskBuilder_ == null) {
- updateMask_ = null;
- onChanged();
- } else {
- updateMask_ = null;
- updateMaskBuilder_ = null;
- }
-
- return this;
- }
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- */
- public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() {
-
- onChanged();
- return getUpdateMaskFieldBuilder().getBuilder();
- }
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- */
- public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() {
- if (updateMaskBuilder_ != null) {
- return updateMaskBuilder_.getMessageOrBuilder();
- } else {
- return updateMask_ == null
- ? com.google.protobuf.FieldMask.getDefaultInstance()
- : updateMask_;
- }
- }
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- */
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.protobuf.FieldMask,
- com.google.protobuf.FieldMask.Builder,
- com.google.protobuf.FieldMaskOrBuilder>
- getUpdateMaskFieldBuilder() {
- if (updateMaskBuilder_ == null) {
- updateMaskBuilder_ =
- new com.google.protobuf.SingleFieldBuilderV3<
- com.google.protobuf.FieldMask,
- com.google.protobuf.FieldMask.Builder,
- com.google.protobuf.FieldMaskOrBuilder>(
- getUpdateMask(), getParentForChildren(), isClean());
- updateMask_ = null;
- }
- return updateMaskBuilder_;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v1.SetIamPolicyRequest)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v1.SetIamPolicyRequest)
- private static final com.google.iam.v1.SetIamPolicyRequest DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v1.SetIamPolicyRequest();
- }
-
- public static com.google.iam.v1.SetIamPolicyRequest getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The resource.
- */
- java.lang.String getResource();
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy is being specified. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The bytes for resource.
- */
- com.google.protobuf.ByteString getResourceBytes();
-
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return Whether the policy field is set.
- */
- boolean hasPolicy();
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The policy.
- */
- com.google.iam.v1.Policy getPolicy();
- /**
- *
- *
- * - * REQUIRED: The complete policy to be applied to the `resource`. The size of - * the policy is limited to a few 10s of KB. An empty policy is a - * valid policy but certain Cloud Platform services (such as Projects) - * might reject them. - *- * - *
.google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder();
-
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- *
- * @return Whether the updateMask field is set.
- */
- boolean hasUpdateMask();
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- *
- * @return The updateMask.
- */
- com.google.protobuf.FieldMask getUpdateMask();
- /**
- *
- *
- * - * OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only - * the fields in the mask will be modified. If no mask is provided, the - * following default mask is used: - * `paths: "bindings, etag"` - *- * - *
.google.protobuf.FieldMask update_mask = 3;
- */
- com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder();
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsRequest.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsRequest.java
deleted file mode 100644
index cb5dab7d..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsRequest.java
+++ /dev/null
@@ -1,947 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/iam_policy.proto
-
-package com.google.iam.v1;
-
-/**
- *
- *
- * - * Request message for `TestIamPermissions` method. - *- * - * Protobuf type {@code google.iam.v1.TestIamPermissionsRequest} - */ -public final class TestIamPermissionsRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.TestIamPermissionsRequest) - TestIamPermissionsRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use TestIamPermissionsRequest.newBuilder() to construct. - private TestIamPermissionsRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private TestIamPermissionsRequest() { - resource_ = ""; - permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new TestIamPermissionsRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.IamPolicyProto - .internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.IamPolicyProto - .internal_static_google_iam_v1_TestIamPermissionsRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.TestIamPermissionsRequest.class, - com.google.iam.v1.TestIamPermissionsRequest.Builder.class); - } - - public static final int RESOURCE_FIELD_NUMBER = 1; - private volatile java.lang.Object resource_; - /** - * - * - *
- * REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The resource.
- */
- @java.lang.Override
- public java.lang.String getResource() {
- java.lang.Object ref = resource_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- resource_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The bytes for resource.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getResourceBytes() {
- java.lang.Object ref = resource_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- resource_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- public static final int PERMISSIONS_FIELD_NUMBER = 2;
- private com.google.protobuf.LazyStringList permissions_;
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return A list containing the permissions.
- */
- public com.google.protobuf.ProtocolStringList getPermissionsList() {
- return permissions_;
- }
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The count of permissions.
- */
- public int getPermissionsCount() {
- return permissions_.size();
- }
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param index The index of the element to return.
- * @return The permissions at the given index.
- */
- public java.lang.String getPermissions(int index) {
- return permissions_.get(index);
- }
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param index The index of the value to return.
- * @return The bytes of the permissions at the given index.
- */
- public com.google.protobuf.ByteString getPermissionsBytes(int index) {
- return permissions_.getByteString(index);
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resource_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resource_);
- }
- for (int i = 0; i < permissions_.size(); i++) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 2, permissions_.getRaw(i));
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resource_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, resource_);
- }
- {
- int dataSize = 0;
- for (int i = 0; i < permissions_.size(); i++) {
- dataSize += computeStringSizeNoTag(permissions_.getRaw(i));
- }
- size += dataSize;
- size += 1 * getPermissionsList().size();
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.TestIamPermissionsRequest)) {
- return super.equals(obj);
- }
- com.google.iam.v1.TestIamPermissionsRequest other =
- (com.google.iam.v1.TestIamPermissionsRequest) obj;
-
- if (!getResource().equals(other.getResource())) return false;
- if (!getPermissionsList().equals(other.getPermissionsList())) return false;
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + RESOURCE_FIELD_NUMBER;
- hash = (53 * hash) + getResource().hashCode();
- if (getPermissionsCount() > 0) {
- hash = (37 * hash) + PERMISSIONS_FIELD_NUMBER;
- hash = (53 * hash) + getPermissionsList().hashCode();
- }
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(
- com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseDelimitedFrom(
- java.io.InputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(
- com.google.protobuf.CodedInputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.TestIamPermissionsRequest prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * Request message for `TestIamPermissions` method. - *- * - * Protobuf type {@code google.iam.v1.TestIamPermissionsRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The resource.
- */
- public java.lang.String getResource() {
- java.lang.Object ref = resource_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- resource_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The bytes for resource.
- */
- public com.google.protobuf.ByteString getResourceBytes() {
- java.lang.Object ref = resource_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- resource_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @param value The resource to set.
- * @return This builder for chaining.
- */
- public Builder setResource(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- resource_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return This builder for chaining.
- */
- public Builder clearResource() {
-
- resource_ = getDefaultInstance().getResource();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @param value The bytes for resource to set.
- * @return This builder for chaining.
- */
- public Builder setResourceBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- resource_ = value;
- onChanged();
- return this;
- }
-
- private com.google.protobuf.LazyStringList permissions_ =
- com.google.protobuf.LazyStringArrayList.EMPTY;
-
- private void ensurePermissionsIsMutable() {
- if (!((bitField0_ & 0x00000001) != 0)) {
- permissions_ = new com.google.protobuf.LazyStringArrayList(permissions_);
- bitField0_ |= 0x00000001;
- }
- }
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return A list containing the permissions.
- */
- public com.google.protobuf.ProtocolStringList getPermissionsList() {
- return permissions_.getUnmodifiableView();
- }
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The count of permissions.
- */
- public int getPermissionsCount() {
- return permissions_.size();
- }
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param index The index of the element to return.
- * @return The permissions at the given index.
- */
- public java.lang.String getPermissions(int index) {
- return permissions_.get(index);
- }
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param index The index of the value to return.
- * @return The bytes of the permissions at the given index.
- */
- public com.google.protobuf.ByteString getPermissionsBytes(int index) {
- return permissions_.getByteString(index);
- }
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param index The index to set the value at.
- * @param value The permissions to set.
- * @return This builder for chaining.
- */
- public Builder setPermissions(int index, java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensurePermissionsIsMutable();
- permissions_.set(index, value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param value The permissions to add.
- * @return This builder for chaining.
- */
- public Builder addPermissions(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensurePermissionsIsMutable();
- permissions_.add(value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param values The permissions to add.
- * @return This builder for chaining.
- */
- public Builder addAllPermissions(java.lang.Iterable- * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return This builder for chaining.
- */
- public Builder clearPermissions() {
- permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000001);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param value The bytes of the permissions to add.
- * @return This builder for chaining.
- */
- public Builder addPermissionsBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
- ensurePermissionsIsMutable();
- permissions_.add(value);
- onChanged();
- return this;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v1.TestIamPermissionsRequest)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v1.TestIamPermissionsRequest)
- private static final com.google.iam.v1.TestIamPermissionsRequest DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v1.TestIamPermissionsRequest();
- }
-
- public static com.google.iam.v1.TestIamPermissionsRequest getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The resource.
- */
- java.lang.String getResource();
- /**
- *
- *
- * - * REQUIRED: The resource for which the policy detail is being requested. - * See the operation documentation for the appropriate value for this field. - *- * - *
- * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
- *
- *
- * @return The bytes for resource.
- */
- com.google.protobuf.ByteString getResourceBytes();
-
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return A list containing the permissions.
- */
- java.util.List- * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The count of permissions.
- */
- int getPermissionsCount();
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param index The index of the element to return.
- * @return The permissions at the given index.
- */
- java.lang.String getPermissions(int index);
- /**
- *
- *
- * - * The set of permissions to check for the `resource`. Permissions with - * wildcards (such as '*' or 'storage.*') are not allowed. For more - * information see - * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). - *- * - *
repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param index The index of the value to return.
- * @return The bytes of the permissions at the given index.
- */
- com.google.protobuf.ByteString getPermissionsBytes(int index);
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsResponse.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsResponse.java
deleted file mode 100644
index fbe4f1a3..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsResponse.java
+++ /dev/null
@@ -1,722 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/iam_policy.proto
-
-package com.google.iam.v1;
-
-/**
- *
- *
- * - * Response message for `TestIamPermissions` method. - *- * - * Protobuf type {@code google.iam.v1.TestIamPermissionsResponse} - */ -public final class TestIamPermissionsResponse extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.TestIamPermissionsResponse) - TestIamPermissionsResponseOrBuilder { - private static final long serialVersionUID = 0L; - // Use TestIamPermissionsResponse.newBuilder() to construct. - private TestIamPermissionsResponse(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private TestIamPermissionsResponse() { - permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new TestIamPermissionsResponse(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.IamPolicyProto - .internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.IamPolicyProto - .internal_static_google_iam_v1_TestIamPermissionsResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.TestIamPermissionsResponse.class, - com.google.iam.v1.TestIamPermissionsResponse.Builder.class); - } - - public static final int PERMISSIONS_FIELD_NUMBER = 1; - private com.google.protobuf.LazyStringList permissions_; - /** - * - * - *
- * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @return A list containing the permissions.
- */
- public com.google.protobuf.ProtocolStringList getPermissionsList() {
- return permissions_;
- }
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @return The count of permissions.
- */
- public int getPermissionsCount() {
- return permissions_.size();
- }
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @param index The index of the element to return.
- * @return The permissions at the given index.
- */
- public java.lang.String getPermissions(int index) {
- return permissions_.get(index);
- }
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @param index The index of the value to return.
- * @return The bytes of the permissions at the given index.
- */
- public com.google.protobuf.ByteString getPermissionsBytes(int index) {
- return permissions_.getByteString(index);
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- for (int i = 0; i < permissions_.size(); i++) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 1, permissions_.getRaw(i));
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- {
- int dataSize = 0;
- for (int i = 0; i < permissions_.size(); i++) {
- dataSize += computeStringSizeNoTag(permissions_.getRaw(i));
- }
- size += dataSize;
- size += 1 * getPermissionsList().size();
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.TestIamPermissionsResponse)) {
- return super.equals(obj);
- }
- com.google.iam.v1.TestIamPermissionsResponse other =
- (com.google.iam.v1.TestIamPermissionsResponse) obj;
-
- if (!getPermissionsList().equals(other.getPermissionsList())) return false;
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- if (getPermissionsCount() > 0) {
- hash = (37 * hash) + PERMISSIONS_FIELD_NUMBER;
- hash = (53 * hash) + getPermissionsList().hashCode();
- }
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(
- com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseDelimitedFrom(
- java.io.InputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(
- com.google.protobuf.CodedInputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.TestIamPermissionsResponse prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * Response message for `TestIamPermissions` method. - *- * - * Protobuf type {@code google.iam.v1.TestIamPermissionsResponse} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @return A list containing the permissions.
- */
- public com.google.protobuf.ProtocolStringList getPermissionsList() {
- return permissions_.getUnmodifiableView();
- }
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @return The count of permissions.
- */
- public int getPermissionsCount() {
- return permissions_.size();
- }
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @param index The index of the element to return.
- * @return The permissions at the given index.
- */
- public java.lang.String getPermissions(int index) {
- return permissions_.get(index);
- }
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @param index The index of the value to return.
- * @return The bytes of the permissions at the given index.
- */
- public com.google.protobuf.ByteString getPermissionsBytes(int index) {
- return permissions_.getByteString(index);
- }
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @param index The index to set the value at.
- * @param value The permissions to set.
- * @return This builder for chaining.
- */
- public Builder setPermissions(int index, java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensurePermissionsIsMutable();
- permissions_.set(index, value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @param value The permissions to add.
- * @return This builder for chaining.
- */
- public Builder addPermissions(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensurePermissionsIsMutable();
- permissions_.add(value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @param values The permissions to add.
- * @return This builder for chaining.
- */
- public Builder addAllPermissions(java.lang.Iterable- * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @return This builder for chaining.
- */
- public Builder clearPermissions() {
- permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000001);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @param value The bytes of the permissions to add.
- * @return This builder for chaining.
- */
- public Builder addPermissionsBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
- ensurePermissionsIsMutable();
- permissions_.add(value);
- onChanged();
- return this;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v1.TestIamPermissionsResponse)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v1.TestIamPermissionsResponse)
- private static final com.google.iam.v1.TestIamPermissionsResponse DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v1.TestIamPermissionsResponse();
- }
-
- public static com.google.iam.v1.TestIamPermissionsResponse getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @return A list containing the permissions.
- */
- java.util.List- * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @return The count of permissions.
- */
- int getPermissionsCount();
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @param index The index of the element to return.
- * @return The permissions at the given index.
- */
- java.lang.String getPermissions(int index);
- /**
- *
- *
- * - * A subset of `TestPermissionsRequest.permissions` that the caller is - * allowed. - *- * - *
repeated string permissions = 1;
- *
- * @param index The index of the value to return.
- * @return The bytes of the permissions at the given index.
- */
- com.google.protobuf.ByteString getPermissionsBytes(int index);
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditData.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditData.java
deleted file mode 100644
index 268cbc4d..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditData.java
+++ /dev/null
@@ -1,729 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/logging/audit_data.proto
-
-package com.google.iam.v1.logging;
-
-/**
- *
- *
- * - * Audit log information specific to Cloud IAM. This message is serialized - * as an `Any` type in the `ServiceData` message of an - * `AuditLog` message. - *- * - * Protobuf type {@code google.iam.v1.logging.AuditData} - */ -public final class AuditData extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v1.logging.AuditData) - AuditDataOrBuilder { - private static final long serialVersionUID = 0L; - // Use AuditData.newBuilder() to construct. - private AuditData(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private AuditData() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new AuditData(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private AuditData( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - com.google.iam.v1.PolicyDelta.Builder subBuilder = null; - if (policyDelta_ != null) { - subBuilder = policyDelta_.toBuilder(); - } - policyDelta_ = - input.readMessage(com.google.iam.v1.PolicyDelta.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(policyDelta_); - policyDelta_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v1.logging.AuditDataProto - .internal_static_google_iam_v1_logging_AuditData_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v1.logging.AuditDataProto - .internal_static_google_iam_v1_logging_AuditData_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v1.logging.AuditData.class, - com.google.iam.v1.logging.AuditData.Builder.class); - } - - public static final int POLICY_DELTA_FIELD_NUMBER = 2; - private com.google.iam.v1.PolicyDelta policyDelta_; - /** - * - * - *
- * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- *
- * @return Whether the policyDelta field is set.
- */
- @java.lang.Override
- public boolean hasPolicyDelta() {
- return policyDelta_ != null;
- }
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- *
- * @return The policyDelta.
- */
- @java.lang.Override
- public com.google.iam.v1.PolicyDelta getPolicyDelta() {
- return policyDelta_ == null ? com.google.iam.v1.PolicyDelta.getDefaultInstance() : policyDelta_;
- }
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- */
- @java.lang.Override
- public com.google.iam.v1.PolicyDeltaOrBuilder getPolicyDeltaOrBuilder() {
- return getPolicyDelta();
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (policyDelta_ != null) {
- output.writeMessage(2, getPolicyDelta());
- }
- unknownFields.writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (policyDelta_ != null) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getPolicyDelta());
- }
- size += unknownFields.getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v1.logging.AuditData)) {
- return super.equals(obj);
- }
- com.google.iam.v1.logging.AuditData other = (com.google.iam.v1.logging.AuditData) obj;
-
- if (hasPolicyDelta() != other.hasPolicyDelta()) return false;
- if (hasPolicyDelta()) {
- if (!getPolicyDelta().equals(other.getPolicyDelta())) return false;
- }
- if (!unknownFields.equals(other.unknownFields)) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- if (hasPolicyDelta()) {
- hash = (37 * hash) + POLICY_DELTA_FIELD_NUMBER;
- hash = (53 * hash) + getPolicyDelta().hashCode();
- }
- hash = (29 * hash) + unknownFields.hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v1.logging.AuditData parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.logging.AuditData parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.logging.AuditData parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.logging.AuditData parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.logging.AuditData parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v1.logging.AuditData parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v1.logging.AuditData parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.logging.AuditData parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.logging.AuditData parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.logging.AuditData parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v1.logging.AuditData parseFrom(
- com.google.protobuf.CodedInputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v1.logging.AuditData parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v1.logging.AuditData prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * Audit log information specific to Cloud IAM. This message is serialized - * as an `Any` type in the `ServiceData` message of an - * `AuditLog` message. - *- * - * Protobuf type {@code google.iam.v1.logging.AuditData} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- *
- * @return Whether the policyDelta field is set.
- */
- public boolean hasPolicyDelta() {
- return policyDeltaBuilder_ != null || policyDelta_ != null;
- }
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- *
- * @return The policyDelta.
- */
- public com.google.iam.v1.PolicyDelta getPolicyDelta() {
- if (policyDeltaBuilder_ == null) {
- return policyDelta_ == null
- ? com.google.iam.v1.PolicyDelta.getDefaultInstance()
- : policyDelta_;
- } else {
- return policyDeltaBuilder_.getMessage();
- }
- }
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- */
- public Builder setPolicyDelta(com.google.iam.v1.PolicyDelta value) {
- if (policyDeltaBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- policyDelta_ = value;
- onChanged();
- } else {
- policyDeltaBuilder_.setMessage(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- */
- public Builder setPolicyDelta(com.google.iam.v1.PolicyDelta.Builder builderForValue) {
- if (policyDeltaBuilder_ == null) {
- policyDelta_ = builderForValue.build();
- onChanged();
- } else {
- policyDeltaBuilder_.setMessage(builderForValue.build());
- }
-
- return this;
- }
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- */
- public Builder mergePolicyDelta(com.google.iam.v1.PolicyDelta value) {
- if (policyDeltaBuilder_ == null) {
- if (policyDelta_ != null) {
- policyDelta_ =
- com.google.iam.v1.PolicyDelta.newBuilder(policyDelta_)
- .mergeFrom(value)
- .buildPartial();
- } else {
- policyDelta_ = value;
- }
- onChanged();
- } else {
- policyDeltaBuilder_.mergeFrom(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- */
- public Builder clearPolicyDelta() {
- if (policyDeltaBuilder_ == null) {
- policyDelta_ = null;
- onChanged();
- } else {
- policyDelta_ = null;
- policyDeltaBuilder_ = null;
- }
-
- return this;
- }
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- */
- public com.google.iam.v1.PolicyDelta.Builder getPolicyDeltaBuilder() {
-
- onChanged();
- return getPolicyDeltaFieldBuilder().getBuilder();
- }
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- */
- public com.google.iam.v1.PolicyDeltaOrBuilder getPolicyDeltaOrBuilder() {
- if (policyDeltaBuilder_ != null) {
- return policyDeltaBuilder_.getMessageOrBuilder();
- } else {
- return policyDelta_ == null
- ? com.google.iam.v1.PolicyDelta.getDefaultInstance()
- : policyDelta_;
- }
- }
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- */
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.iam.v1.PolicyDelta,
- com.google.iam.v1.PolicyDelta.Builder,
- com.google.iam.v1.PolicyDeltaOrBuilder>
- getPolicyDeltaFieldBuilder() {
- if (policyDeltaBuilder_ == null) {
- policyDeltaBuilder_ =
- new com.google.protobuf.SingleFieldBuilderV3<
- com.google.iam.v1.PolicyDelta,
- com.google.iam.v1.PolicyDelta.Builder,
- com.google.iam.v1.PolicyDeltaOrBuilder>(
- getPolicyDelta(), getParentForChildren(), isClean());
- policyDelta_ = null;
- }
- return policyDeltaBuilder_;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v1.logging.AuditData)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v1.logging.AuditData)
- private static final com.google.iam.v1.logging.AuditData DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v1.logging.AuditData();
- }
-
- public static com.google.iam.v1.logging.AuditData getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- *
- * @return Whether the policyDelta field is set.
- */
- boolean hasPolicyDelta();
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- *
- * @return The policyDelta.
- */
- com.google.iam.v1.PolicyDelta getPolicyDelta();
- /**
- *
- *
- * - * Policy delta between the original policy and the newly set policy. - *- * - *
.google.iam.v1.PolicyDelta policy_delta = 2;
- */
- com.google.iam.v1.PolicyDeltaOrBuilder getPolicyDeltaOrBuilder();
-}
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditDataProto.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditDataProto.java
deleted file mode 100644
index 7a5309a6..00000000
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditDataProto.java
+++ /dev/null
@@ -1,73 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v1/logging/audit_data.proto
-
-package com.google.iam.v1.logging;
-
-public final class AuditDataProto {
- private AuditDataProto() {}
-
- public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {}
-
- public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) {
- registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry);
- }
-
- static final com.google.protobuf.Descriptors.Descriptor
- internal_static_google_iam_v1_logging_AuditData_descriptor;
- static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
- internal_static_google_iam_v1_logging_AuditData_fieldAccessorTable;
-
- public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
- return descriptor;
- }
-
- private static com.google.protobuf.Descriptors.FileDescriptor descriptor;
-
- static {
- java.lang.String[] descriptorData = {
- "\n&google/iam/v1/logging/audit_data.proto"
- + "\022\025google.iam.v1.logging\032\034google/api/anno"
- + "tations.proto\032\032google/iam/v1/policy.prot"
- + "o\"=\n\tAuditData\0220\n\014policy_delta\030\002 \001(\0132\032.g"
- + "oogle.iam.v1.PolicyDeltaB\211\001\n\031com.google."
- + "iam.v1.loggingB\016AuditDataProtoP\001Z- * Request message for `CreatePolicy`. - *- * - * Protobuf type {@code google.iam.v2.CreatePolicyRequest} - */ -public final class CreatePolicyRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v2.CreatePolicyRequest) - CreatePolicyRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use CreatePolicyRequest.newBuilder() to construct. - private CreatePolicyRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private CreatePolicyRequest() { - parent_ = ""; - policyId_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new CreatePolicyRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v2.PolicyProto - .internal_static_google_iam_v2_CreatePolicyRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v2.PolicyProto - .internal_static_google_iam_v2_CreatePolicyRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v2.CreatePolicyRequest.class, - com.google.iam.v2.CreatePolicyRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 1; - private volatile java.lang.Object parent_; - /** - * - * - *
- * Required. The resource that the policy is attached to, along with the kind of policy - * to create. Format: `policies/{attachment_point}/denypolicies` - * The attachment point is identified by its URL-encoded full resource name, - * which means that the forward-slash character, `/`, must be written as - * `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string parent = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The parent.
- */
- @java.lang.Override
- public java.lang.String getParent() {
- java.lang.Object ref = parent_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- parent_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * Required. The resource that the policy is attached to, along with the kind of policy - * to create. Format: `policies/{attachment_point}/denypolicies` - * The attachment point is identified by its URL-encoded full resource name, - * which means that the forward-slash character, `/`, must be written as - * `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string parent = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The bytes for parent.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getParentBytes() {
- java.lang.Object ref = parent_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- parent_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- public static final int POLICY_FIELD_NUMBER = 2;
- private com.google.iam.v2.Policy policy_;
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return Whether the policy field is set.
- */
- @java.lang.Override
- public boolean hasPolicy() {
- return policy_ != null;
- }
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The policy.
- */
- @java.lang.Override
- public com.google.iam.v2.Policy getPolicy() {
- return policy_ == null ? com.google.iam.v2.Policy.getDefaultInstance() : policy_;
- }
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- @java.lang.Override
- public com.google.iam.v2.PolicyOrBuilder getPolicyOrBuilder() {
- return getPolicy();
- }
-
- public static final int POLICY_ID_FIELD_NUMBER = 3;
- private volatile java.lang.Object policyId_;
- /**
- *
- *
- * - * The ID to use for this policy, which will become the final component of - * the policy's resource name. The ID must contain 3 to 63 characters. It can - * contain lowercase letters and numbers, as well as dashes (`-`) and periods - * (`.`). The first character must be a lowercase letter. - *- * - *
string policy_id = 3;
- *
- * @return The policyId.
- */
- @java.lang.Override
- public java.lang.String getPolicyId() {
- java.lang.Object ref = policyId_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- policyId_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * The ID to use for this policy, which will become the final component of - * the policy's resource name. The ID must contain 3 to 63 characters. It can - * contain lowercase letters and numbers, as well as dashes (`-`) and periods - * (`.`). The first character must be a lowercase letter. - *- * - *
string policy_id = 3;
- *
- * @return The bytes for policyId.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getPolicyIdBytes() {
- java.lang.Object ref = policyId_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- policyId_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_);
- }
- if (policy_ != null) {
- output.writeMessage(2, getPolicy());
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(policyId_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 3, policyId_);
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_);
- }
- if (policy_ != null) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getPolicy());
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(policyId_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, policyId_);
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v2.CreatePolicyRequest)) {
- return super.equals(obj);
- }
- com.google.iam.v2.CreatePolicyRequest other = (com.google.iam.v2.CreatePolicyRequest) obj;
-
- if (!getParent().equals(other.getParent())) return false;
- if (hasPolicy() != other.hasPolicy()) return false;
- if (hasPolicy()) {
- if (!getPolicy().equals(other.getPolicy())) return false;
- }
- if (!getPolicyId().equals(other.getPolicyId())) return false;
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + PARENT_FIELD_NUMBER;
- hash = (53 * hash) + getParent().hashCode();
- if (hasPolicy()) {
- hash = (37 * hash) + POLICY_FIELD_NUMBER;
- hash = (53 * hash) + getPolicy().hashCode();
- }
- hash = (37 * hash) + POLICY_ID_FIELD_NUMBER;
- hash = (53 * hash) + getPolicyId().hashCode();
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseFrom(
- com.google.protobuf.CodedInputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v2.CreatePolicyRequest parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v2.CreatePolicyRequest prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * Request message for `CreatePolicy`. - *- * - * Protobuf type {@code google.iam.v2.CreatePolicyRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * Required. The resource that the policy is attached to, along with the kind of policy - * to create. Format: `policies/{attachment_point}/denypolicies` - * The attachment point is identified by its URL-encoded full resource name, - * which means that the forward-slash character, `/`, must be written as - * `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string parent = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The parent.
- */
- public java.lang.String getParent() {
- java.lang.Object ref = parent_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- parent_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * Required. The resource that the policy is attached to, along with the kind of policy - * to create. Format: `policies/{attachment_point}/denypolicies` - * The attachment point is identified by its URL-encoded full resource name, - * which means that the forward-slash character, `/`, must be written as - * `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string parent = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The bytes for parent.
- */
- public com.google.protobuf.ByteString getParentBytes() {
- java.lang.Object ref = parent_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- parent_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * Required. The resource that the policy is attached to, along with the kind of policy - * to create. Format: `policies/{attachment_point}/denypolicies` - * The attachment point is identified by its URL-encoded full resource name, - * which means that the forward-slash character, `/`, must be written as - * `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string parent = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param value The parent to set.
- * @return This builder for chaining.
- */
- public Builder setParent(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- parent_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Required. The resource that the policy is attached to, along with the kind of policy - * to create. Format: `policies/{attachment_point}/denypolicies` - * The attachment point is identified by its URL-encoded full resource name, - * which means that the forward-slash character, `/`, must be written as - * `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string parent = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return This builder for chaining.
- */
- public Builder clearParent() {
-
- parent_ = getDefaultInstance().getParent();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Required. The resource that the policy is attached to, along with the kind of policy - * to create. Format: `policies/{attachment_point}/denypolicies` - * The attachment point is identified by its URL-encoded full resource name, - * which means that the forward-slash character, `/`, must be written as - * `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string parent = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param value The bytes for parent to set.
- * @return This builder for chaining.
- */
- public Builder setParentBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- parent_ = value;
- onChanged();
- return this;
- }
-
- private com.google.iam.v2.Policy policy_;
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.iam.v2.Policy,
- com.google.iam.v2.Policy.Builder,
- com.google.iam.v2.PolicyOrBuilder>
- policyBuilder_;
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return Whether the policy field is set.
- */
- public boolean hasPolicy() {
- return policyBuilder_ != null || policy_ != null;
- }
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The policy.
- */
- public com.google.iam.v2.Policy getPolicy() {
- if (policyBuilder_ == null) {
- return policy_ == null ? com.google.iam.v2.Policy.getDefaultInstance() : policy_;
- } else {
- return policyBuilder_.getMessage();
- }
- }
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public Builder setPolicy(com.google.iam.v2.Policy value) {
- if (policyBuilder_ == null) {
- if (value == null) {
- throw new NullPointerException();
- }
- policy_ = value;
- onChanged();
- } else {
- policyBuilder_.setMessage(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public Builder setPolicy(com.google.iam.v2.Policy.Builder builderForValue) {
- if (policyBuilder_ == null) {
- policy_ = builderForValue.build();
- onChanged();
- } else {
- policyBuilder_.setMessage(builderForValue.build());
- }
-
- return this;
- }
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public Builder mergePolicy(com.google.iam.v2.Policy value) {
- if (policyBuilder_ == null) {
- if (policy_ != null) {
- policy_ = com.google.iam.v2.Policy.newBuilder(policy_).mergeFrom(value).buildPartial();
- } else {
- policy_ = value;
- }
- onChanged();
- } else {
- policyBuilder_.mergeFrom(value);
- }
-
- return this;
- }
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public Builder clearPolicy() {
- if (policyBuilder_ == null) {
- policy_ = null;
- onChanged();
- } else {
- policy_ = null;
- policyBuilder_ = null;
- }
-
- return this;
- }
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public com.google.iam.v2.Policy.Builder getPolicyBuilder() {
-
- onChanged();
- return getPolicyFieldBuilder().getBuilder();
- }
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- public com.google.iam.v2.PolicyOrBuilder getPolicyOrBuilder() {
- if (policyBuilder_ != null) {
- return policyBuilder_.getMessageOrBuilder();
- } else {
- return policy_ == null ? com.google.iam.v2.Policy.getDefaultInstance() : policy_;
- }
- }
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- private com.google.protobuf.SingleFieldBuilderV3<
- com.google.iam.v2.Policy,
- com.google.iam.v2.Policy.Builder,
- com.google.iam.v2.PolicyOrBuilder>
- getPolicyFieldBuilder() {
- if (policyBuilder_ == null) {
- policyBuilder_ =
- new com.google.protobuf.SingleFieldBuilderV3<
- com.google.iam.v2.Policy,
- com.google.iam.v2.Policy.Builder,
- com.google.iam.v2.PolicyOrBuilder>(getPolicy(), getParentForChildren(), isClean());
- policy_ = null;
- }
- return policyBuilder_;
- }
-
- private java.lang.Object policyId_ = "";
- /**
- *
- *
- * - * The ID to use for this policy, which will become the final component of - * the policy's resource name. The ID must contain 3 to 63 characters. It can - * contain lowercase letters and numbers, as well as dashes (`-`) and periods - * (`.`). The first character must be a lowercase letter. - *- * - *
string policy_id = 3;
- *
- * @return The policyId.
- */
- public java.lang.String getPolicyId() {
- java.lang.Object ref = policyId_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- policyId_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * The ID to use for this policy, which will become the final component of - * the policy's resource name. The ID must contain 3 to 63 characters. It can - * contain lowercase letters and numbers, as well as dashes (`-`) and periods - * (`.`). The first character must be a lowercase letter. - *- * - *
string policy_id = 3;
- *
- * @return The bytes for policyId.
- */
- public com.google.protobuf.ByteString getPolicyIdBytes() {
- java.lang.Object ref = policyId_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- policyId_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * The ID to use for this policy, which will become the final component of - * the policy's resource name. The ID must contain 3 to 63 characters. It can - * contain lowercase letters and numbers, as well as dashes (`-`) and periods - * (`.`). The first character must be a lowercase letter. - *- * - *
string policy_id = 3;
- *
- * @param value The policyId to set.
- * @return This builder for chaining.
- */
- public Builder setPolicyId(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- policyId_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The ID to use for this policy, which will become the final component of - * the policy's resource name. The ID must contain 3 to 63 characters. It can - * contain lowercase letters and numbers, as well as dashes (`-`) and periods - * (`.`). The first character must be a lowercase letter. - *- * - *
string policy_id = 3;
- *
- * @return This builder for chaining.
- */
- public Builder clearPolicyId() {
-
- policyId_ = getDefaultInstance().getPolicyId();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The ID to use for this policy, which will become the final component of - * the policy's resource name. The ID must contain 3 to 63 characters. It can - * contain lowercase letters and numbers, as well as dashes (`-`) and periods - * (`.`). The first character must be a lowercase letter. - *- * - *
string policy_id = 3;
- *
- * @param value The bytes for policyId to set.
- * @return This builder for chaining.
- */
- public Builder setPolicyIdBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- policyId_ = value;
- onChanged();
- return this;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v2.CreatePolicyRequest)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v2.CreatePolicyRequest)
- private static final com.google.iam.v2.CreatePolicyRequest DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v2.CreatePolicyRequest();
- }
-
- public static com.google.iam.v2.CreatePolicyRequest getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * Required. The resource that the policy is attached to, along with the kind of policy - * to create. Format: `policies/{attachment_point}/denypolicies` - * The attachment point is identified by its URL-encoded full resource name, - * which means that the forward-slash character, `/`, must be written as - * `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string parent = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The parent.
- */
- java.lang.String getParent();
- /**
- *
- *
- * - * Required. The resource that the policy is attached to, along with the kind of policy - * to create. Format: `policies/{attachment_point}/denypolicies` - * The attachment point is identified by its URL-encoded full resource name, - * which means that the forward-slash character, `/`, must be written as - * `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string parent = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The bytes for parent.
- */
- com.google.protobuf.ByteString getParentBytes();
-
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return Whether the policy field is set.
- */
- boolean hasPolicy();
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The policy.
- */
- com.google.iam.v2.Policy getPolicy();
- /**
- *
- *
- * - * Required. The policy to create. - *- * - *
.google.iam.v2.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED];
- */
- com.google.iam.v2.PolicyOrBuilder getPolicyOrBuilder();
-
- /**
- *
- *
- * - * The ID to use for this policy, which will become the final component of - * the policy's resource name. The ID must contain 3 to 63 characters. It can - * contain lowercase letters and numbers, as well as dashes (`-`) and periods - * (`.`). The first character must be a lowercase letter. - *- * - *
string policy_id = 3;
- *
- * @return The policyId.
- */
- java.lang.String getPolicyId();
- /**
- *
- *
- * - * The ID to use for this policy, which will become the final component of - * the policy's resource name. The ID must contain 3 to 63 characters. It can - * contain lowercase letters and numbers, as well as dashes (`-`) and periods - * (`.`). The first character must be a lowercase letter. - *- * - *
string policy_id = 3;
- *
- * @return The bytes for policyId.
- */
- com.google.protobuf.ByteString getPolicyIdBytes();
-}
diff --git a/proto-google-iam-v2/src/main/java/com/google/iam/v2/DeletePolicyRequest.java b/proto-google-iam-v2/src/main/java/com/google/iam/v2/DeletePolicyRequest.java
deleted file mode 100644
index 3900d3dc..00000000
--- a/proto-google-iam-v2/src/main/java/com/google/iam/v2/DeletePolicyRequest.java
+++ /dev/null
@@ -1,860 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v2/policy.proto
-
-package com.google.iam.v2;
-
-/**
- *
- *
- * - * Request message for `DeletePolicy`. - *- * - * Protobuf type {@code google.iam.v2.DeletePolicyRequest} - */ -public final class DeletePolicyRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v2.DeletePolicyRequest) - DeletePolicyRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use DeletePolicyRequest.newBuilder() to construct. - private DeletePolicyRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private DeletePolicyRequest() { - name_ = ""; - etag_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new DeletePolicyRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v2.PolicyProto - .internal_static_google_iam_v2_DeletePolicyRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v2.PolicyProto - .internal_static_google_iam_v2_DeletePolicyRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v2.DeletePolicyRequest.class, - com.google.iam.v2.DeletePolicyRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
- * Required. The resource name of the policy to delete. Format: - * `policies/{attachment_point}/denypolicies/{policy_id}` - * Use the URL-encoded full resource name, which means that the forward-slash - * character, `/`, must be written as `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies/my-policy`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string name = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The name.
- */
- @java.lang.Override
- public java.lang.String getName() {
- java.lang.Object ref = name_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- name_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * Required. The resource name of the policy to delete. Format: - * `policies/{attachment_point}/denypolicies/{policy_id}` - * Use the URL-encoded full resource name, which means that the forward-slash - * character, `/`, must be written as `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies/my-policy`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string name = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The bytes for name.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getNameBytes() {
- java.lang.Object ref = name_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- name_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- public static final int ETAG_FIELD_NUMBER = 2;
- private volatile java.lang.Object etag_;
- /**
- *
- *
- * - * Optional. The expected `etag` of the policy to delete. If the value does not match - * the value that is stored in IAM, the request fails with a `409` error code - * and `ABORTED` status. - * If you omit this field, the policy is deleted regardless of its current - * `etag`. - *- * - *
string etag = 2 [(.google.api.field_behavior) = OPTIONAL];
- *
- * @return The etag.
- */
- @java.lang.Override
- public java.lang.String getEtag() {
- java.lang.Object ref = etag_;
- if (ref instanceof java.lang.String) {
- return (java.lang.String) ref;
- } else {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- etag_ = s;
- return s;
- }
- }
- /**
- *
- *
- * - * Optional. The expected `etag` of the policy to delete. If the value does not match - * the value that is stored in IAM, the request fails with a `409` error code - * and `ABORTED` status. - * If you omit this field, the policy is deleted regardless of its current - * `etag`. - *- * - *
string etag = 2 [(.google.api.field_behavior) = OPTIONAL];
- *
- * @return The bytes for etag.
- */
- @java.lang.Override
- public com.google.protobuf.ByteString getEtagBytes() {
- java.lang.Object ref = etag_;
- if (ref instanceof java.lang.String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- etag_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 2, etag_);
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_);
- }
- if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) {
- size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, etag_);
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v2.DeletePolicyRequest)) {
- return super.equals(obj);
- }
- com.google.iam.v2.DeletePolicyRequest other = (com.google.iam.v2.DeletePolicyRequest) obj;
-
- if (!getName().equals(other.getName())) return false;
- if (!getEtag().equals(other.getEtag())) return false;
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- hash = (37 * hash) + NAME_FIELD_NUMBER;
- hash = (53 * hash) + getName().hashCode();
- hash = (37 * hash) + ETAG_FIELD_NUMBER;
- hash = (53 * hash) + getEtag().hashCode();
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseFrom(
- com.google.protobuf.CodedInputStream input) throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v2.DeletePolicyRequest parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v2.DeletePolicyRequest prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * Request message for `DeletePolicy`. - *- * - * Protobuf type {@code google.iam.v2.DeletePolicyRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * Required. The resource name of the policy to delete. Format: - * `policies/{attachment_point}/denypolicies/{policy_id}` - * Use the URL-encoded full resource name, which means that the forward-slash - * character, `/`, must be written as `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies/my-policy`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string name = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The name.
- */
- public java.lang.String getName() {
- java.lang.Object ref = name_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- name_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * Required. The resource name of the policy to delete. Format: - * `policies/{attachment_point}/denypolicies/{policy_id}` - * Use the URL-encoded full resource name, which means that the forward-slash - * character, `/`, must be written as `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies/my-policy`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string name = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The bytes for name.
- */
- public com.google.protobuf.ByteString getNameBytes() {
- java.lang.Object ref = name_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- name_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * Required. The resource name of the policy to delete. Format: - * `policies/{attachment_point}/denypolicies/{policy_id}` - * Use the URL-encoded full resource name, which means that the forward-slash - * character, `/`, must be written as `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies/my-policy`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string name = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param value The name to set.
- * @return This builder for chaining.
- */
- public Builder setName(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- name_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Required. The resource name of the policy to delete. Format: - * `policies/{attachment_point}/denypolicies/{policy_id}` - * Use the URL-encoded full resource name, which means that the forward-slash - * character, `/`, must be written as `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies/my-policy`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string name = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return This builder for chaining.
- */
- public Builder clearName() {
-
- name_ = getDefaultInstance().getName();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Required. The resource name of the policy to delete. Format: - * `policies/{attachment_point}/denypolicies/{policy_id}` - * Use the URL-encoded full resource name, which means that the forward-slash - * character, `/`, must be written as `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies/my-policy`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string name = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @param value The bytes for name to set.
- * @return This builder for chaining.
- */
- public Builder setNameBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- name_ = value;
- onChanged();
- return this;
- }
-
- private java.lang.Object etag_ = "";
- /**
- *
- *
- * - * Optional. The expected `etag` of the policy to delete. If the value does not match - * the value that is stored in IAM, the request fails with a `409` error code - * and `ABORTED` status. - * If you omit this field, the policy is deleted regardless of its current - * `etag`. - *- * - *
string etag = 2 [(.google.api.field_behavior) = OPTIONAL];
- *
- * @return The etag.
- */
- public java.lang.String getEtag() {
- java.lang.Object ref = etag_;
- if (!(ref instanceof java.lang.String)) {
- com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
- java.lang.String s = bs.toStringUtf8();
- etag_ = s;
- return s;
- } else {
- return (java.lang.String) ref;
- }
- }
- /**
- *
- *
- * - * Optional. The expected `etag` of the policy to delete. If the value does not match - * the value that is stored in IAM, the request fails with a `409` error code - * and `ABORTED` status. - * If you omit this field, the policy is deleted regardless of its current - * `etag`. - *- * - *
string etag = 2 [(.google.api.field_behavior) = OPTIONAL];
- *
- * @return The bytes for etag.
- */
- public com.google.protobuf.ByteString getEtagBytes() {
- java.lang.Object ref = etag_;
- if (ref instanceof String) {
- com.google.protobuf.ByteString b =
- com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
- etag_ = b;
- return b;
- } else {
- return (com.google.protobuf.ByteString) ref;
- }
- }
- /**
- *
- *
- * - * Optional. The expected `etag` of the policy to delete. If the value does not match - * the value that is stored in IAM, the request fails with a `409` error code - * and `ABORTED` status. - * If you omit this field, the policy is deleted regardless of its current - * `etag`. - *- * - *
string etag = 2 [(.google.api.field_behavior) = OPTIONAL];
- *
- * @param value The etag to set.
- * @return This builder for chaining.
- */
- public Builder setEtag(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
-
- etag_ = value;
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Optional. The expected `etag` of the policy to delete. If the value does not match - * the value that is stored in IAM, the request fails with a `409` error code - * and `ABORTED` status. - * If you omit this field, the policy is deleted regardless of its current - * `etag`. - *- * - *
string etag = 2 [(.google.api.field_behavior) = OPTIONAL];
- *
- * @return This builder for chaining.
- */
- public Builder clearEtag() {
-
- etag_ = getDefaultInstance().getEtag();
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Optional. The expected `etag` of the policy to delete. If the value does not match - * the value that is stored in IAM, the request fails with a `409` error code - * and `ABORTED` status. - * If you omit this field, the policy is deleted regardless of its current - * `etag`. - *- * - *
string etag = 2 [(.google.api.field_behavior) = OPTIONAL];
- *
- * @param value The bytes for etag to set.
- * @return This builder for chaining.
- */
- public Builder setEtagBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
-
- etag_ = value;
- onChanged();
- return this;
- }
-
- @java.lang.Override
- public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.setUnknownFields(unknownFields);
- }
-
- @java.lang.Override
- public final Builder mergeUnknownFields(
- final com.google.protobuf.UnknownFieldSet unknownFields) {
- return super.mergeUnknownFields(unknownFields);
- }
-
- // @@protoc_insertion_point(builder_scope:google.iam.v2.DeletePolicyRequest)
- }
-
- // @@protoc_insertion_point(class_scope:google.iam.v2.DeletePolicyRequest)
- private static final com.google.iam.v2.DeletePolicyRequest DEFAULT_INSTANCE;
-
- static {
- DEFAULT_INSTANCE = new com.google.iam.v2.DeletePolicyRequest();
- }
-
- public static com.google.iam.v2.DeletePolicyRequest getDefaultInstance() {
- return DEFAULT_INSTANCE;
- }
-
- private static final com.google.protobuf.Parser- * Required. The resource name of the policy to delete. Format: - * `policies/{attachment_point}/denypolicies/{policy_id}` - * Use the URL-encoded full resource name, which means that the forward-slash - * character, `/`, must be written as `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies/my-policy`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string name = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The name.
- */
- java.lang.String getName();
- /**
- *
- *
- * - * Required. The resource name of the policy to delete. Format: - * `policies/{attachment_point}/denypolicies/{policy_id}` - * Use the URL-encoded full resource name, which means that the forward-slash - * character, `/`, must be written as `%2F`. For example, - * `policies/cloudresourcemanager.googleapis.com%2Fprojects%2Fmy-project/denypolicies/my-policy`. - * For organizations and folders, use the numeric ID in the full resource - * name. For projects, you can use the alphanumeric or the numeric ID. - *- * - *
string name = 1 [(.google.api.field_behavior) = REQUIRED];
- *
- * @return The bytes for name.
- */
- com.google.protobuf.ByteString getNameBytes();
-
- /**
- *
- *
- * - * Optional. The expected `etag` of the policy to delete. If the value does not match - * the value that is stored in IAM, the request fails with a `409` error code - * and `ABORTED` status. - * If you omit this field, the policy is deleted regardless of its current - * `etag`. - *- * - *
string etag = 2 [(.google.api.field_behavior) = OPTIONAL];
- *
- * @return The etag.
- */
- java.lang.String getEtag();
- /**
- *
- *
- * - * Optional. The expected `etag` of the policy to delete. If the value does not match - * the value that is stored in IAM, the request fails with a `409` error code - * and `ABORTED` status. - * If you omit this field, the policy is deleted regardless of its current - * `etag`. - *- * - *
string etag = 2 [(.google.api.field_behavior) = OPTIONAL];
- *
- * @return The bytes for etag.
- */
- com.google.protobuf.ByteString getEtagBytes();
-}
diff --git a/proto-google-iam-v2/src/main/java/com/google/iam/v2/DenyRule.java b/proto-google-iam-v2/src/main/java/com/google/iam/v2/DenyRule.java
deleted file mode 100644
index f3bc03f5..00000000
--- a/proto-google-iam-v2/src/main/java/com/google/iam/v2/DenyRule.java
+++ /dev/null
@@ -1,2449 +0,0 @@
-/*
- * Copyright 2020 Google LLC
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * https://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-// Generated by the protocol buffer compiler. DO NOT EDIT!
-// source: google/iam/v2/deny.proto
-
-package com.google.iam.v2;
-
-/**
- *
- *
- * - * A deny rule in an IAM deny policy. - *- * - * Protobuf type {@code google.iam.v2.DenyRule} - */ -public final class DenyRule extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.iam.v2.DenyRule) - DenyRuleOrBuilder { - private static final long serialVersionUID = 0L; - // Use DenyRule.newBuilder() to construct. - private DenyRule(com.google.protobuf.GeneratedMessageV3.Builder> builder) { - super(builder); - } - - private DenyRule() { - deniedPrincipals_ = com.google.protobuf.LazyStringArrayList.EMPTY; - exceptionPrincipals_ = com.google.protobuf.LazyStringArrayList.EMPTY; - deniedPermissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; - exceptionPermissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new DenyRule(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.iam.v2.DenyRuleProto.internal_static_google_iam_v2_DenyRule_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.iam.v2.DenyRuleProto.internal_static_google_iam_v2_DenyRule_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.iam.v2.DenyRule.class, com.google.iam.v2.DenyRule.Builder.class); - } - - public static final int DENIED_PRINCIPALS_FIELD_NUMBER = 1; - private com.google.protobuf.LazyStringList deniedPrincipals_; - /** - * - * - *
- * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @return A list containing the deniedPrincipals.
- */
- public com.google.protobuf.ProtocolStringList getDeniedPrincipalsList() {
- return deniedPrincipals_;
- }
- /**
- *
- *
- * - * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @return The count of deniedPrincipals.
- */
- public int getDeniedPrincipalsCount() {
- return deniedPrincipals_.size();
- }
- /**
- *
- *
- * - * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @param index The index of the element to return.
- * @return The deniedPrincipals at the given index.
- */
- public java.lang.String getDeniedPrincipals(int index) {
- return deniedPrincipals_.get(index);
- }
- /**
- *
- *
- * - * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @param index The index of the value to return.
- * @return The bytes of the deniedPrincipals at the given index.
- */
- public com.google.protobuf.ByteString getDeniedPrincipalsBytes(int index) {
- return deniedPrincipals_.getByteString(index);
- }
-
- public static final int EXCEPTION_PRINCIPALS_FIELD_NUMBER = 2;
- private com.google.protobuf.LazyStringList exceptionPrincipals_;
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @return A list containing the exceptionPrincipals.
- */
- public com.google.protobuf.ProtocolStringList getExceptionPrincipalsList() {
- return exceptionPrincipals_;
- }
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @return The count of exceptionPrincipals.
- */
- public int getExceptionPrincipalsCount() {
- return exceptionPrincipals_.size();
- }
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @param index The index of the element to return.
- * @return The exceptionPrincipals at the given index.
- */
- public java.lang.String getExceptionPrincipals(int index) {
- return exceptionPrincipals_.get(index);
- }
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @param index The index of the value to return.
- * @return The bytes of the exceptionPrincipals at the given index.
- */
- public com.google.protobuf.ByteString getExceptionPrincipalsBytes(int index) {
- return exceptionPrincipals_.getByteString(index);
- }
-
- public static final int DENIED_PERMISSIONS_FIELD_NUMBER = 3;
- private com.google.protobuf.LazyStringList deniedPermissions_;
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @return A list containing the deniedPermissions.
- */
- public com.google.protobuf.ProtocolStringList getDeniedPermissionsList() {
- return deniedPermissions_;
- }
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @return The count of deniedPermissions.
- */
- public int getDeniedPermissionsCount() {
- return deniedPermissions_.size();
- }
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @param index The index of the element to return.
- * @return The deniedPermissions at the given index.
- */
- public java.lang.String getDeniedPermissions(int index) {
- return deniedPermissions_.get(index);
- }
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @param index The index of the value to return.
- * @return The bytes of the deniedPermissions at the given index.
- */
- public com.google.protobuf.ByteString getDeniedPermissionsBytes(int index) {
- return deniedPermissions_.getByteString(index);
- }
-
- public static final int EXCEPTION_PERMISSIONS_FIELD_NUMBER = 4;
- private com.google.protobuf.LazyStringList exceptionPermissions_;
- /**
- *
- *
- * - * Specifies the permissions that this rule excludes from the set of denied - * permissions given by `denied_permissions`. If a permission appears in - * `denied_permissions` _and_ in `exception_permissions` then it will _not_ be - * denied. - * The excluded permissions can be specified using the same syntax as - * `denied_permissions`. - *- * - *
repeated string exception_permissions = 4;
- *
- * @return A list containing the exceptionPermissions.
- */
- public com.google.protobuf.ProtocolStringList getExceptionPermissionsList() {
- return exceptionPermissions_;
- }
- /**
- *
- *
- * - * Specifies the permissions that this rule excludes from the set of denied - * permissions given by `denied_permissions`. If a permission appears in - * `denied_permissions` _and_ in `exception_permissions` then it will _not_ be - * denied. - * The excluded permissions can be specified using the same syntax as - * `denied_permissions`. - *- * - *
repeated string exception_permissions = 4;
- *
- * @return The count of exceptionPermissions.
- */
- public int getExceptionPermissionsCount() {
- return exceptionPermissions_.size();
- }
- /**
- *
- *
- * - * Specifies the permissions that this rule excludes from the set of denied - * permissions given by `denied_permissions`. If a permission appears in - * `denied_permissions` _and_ in `exception_permissions` then it will _not_ be - * denied. - * The excluded permissions can be specified using the same syntax as - * `denied_permissions`. - *- * - *
repeated string exception_permissions = 4;
- *
- * @param index The index of the element to return.
- * @return The exceptionPermissions at the given index.
- */
- public java.lang.String getExceptionPermissions(int index) {
- return exceptionPermissions_.get(index);
- }
- /**
- *
- *
- * - * Specifies the permissions that this rule excludes from the set of denied - * permissions given by `denied_permissions`. If a permission appears in - * `denied_permissions` _and_ in `exception_permissions` then it will _not_ be - * denied. - * The excluded permissions can be specified using the same syntax as - * `denied_permissions`. - *- * - *
repeated string exception_permissions = 4;
- *
- * @param index The index of the value to return.
- * @return The bytes of the exceptionPermissions at the given index.
- */
- public com.google.protobuf.ByteString getExceptionPermissionsBytes(int index) {
- return exceptionPermissions_.getByteString(index);
- }
-
- public static final int DENIAL_CONDITION_FIELD_NUMBER = 5;
- private com.google.type.Expr denialCondition_;
- /**
- *
- *
- * - * The condition that determines whether this deny rule applies to a request. - * If the condition expression evaluates to `true`, then the deny rule is - * applied; otherwise, the deny rule is not applied. - * Each deny rule is evaluated independently. If this deny rule does not apply - * to a request, other deny rules might still apply. - * The condition can use CEL functions that evaluate - * [resource - * tags](https://cloud.google.com/iam/help/conditions/resource-tags). Other - * functions and operators are not supported. - *- * - *
.google.type.Expr denial_condition = 5;
- *
- * @return Whether the denialCondition field is set.
- */
- @java.lang.Override
- public boolean hasDenialCondition() {
- return denialCondition_ != null;
- }
- /**
- *
- *
- * - * The condition that determines whether this deny rule applies to a request. - * If the condition expression evaluates to `true`, then the deny rule is - * applied; otherwise, the deny rule is not applied. - * Each deny rule is evaluated independently. If this deny rule does not apply - * to a request, other deny rules might still apply. - * The condition can use CEL functions that evaluate - * [resource - * tags](https://cloud.google.com/iam/help/conditions/resource-tags). Other - * functions and operators are not supported. - *- * - *
.google.type.Expr denial_condition = 5;
- *
- * @return The denialCondition.
- */
- @java.lang.Override
- public com.google.type.Expr getDenialCondition() {
- return denialCondition_ == null ? com.google.type.Expr.getDefaultInstance() : denialCondition_;
- }
- /**
- *
- *
- * - * The condition that determines whether this deny rule applies to a request. - * If the condition expression evaluates to `true`, then the deny rule is - * applied; otherwise, the deny rule is not applied. - * Each deny rule is evaluated independently. If this deny rule does not apply - * to a request, other deny rules might still apply. - * The condition can use CEL functions that evaluate - * [resource - * tags](https://cloud.google.com/iam/help/conditions/resource-tags). Other - * functions and operators are not supported. - *- * - *
.google.type.Expr denial_condition = 5;
- */
- @java.lang.Override
- public com.google.type.ExprOrBuilder getDenialConditionOrBuilder() {
- return getDenialCondition();
- }
-
- private byte memoizedIsInitialized = -1;
-
- @java.lang.Override
- public final boolean isInitialized() {
- byte isInitialized = memoizedIsInitialized;
- if (isInitialized == 1) return true;
- if (isInitialized == 0) return false;
-
- memoizedIsInitialized = 1;
- return true;
- }
-
- @java.lang.Override
- public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
- for (int i = 0; i < deniedPrincipals_.size(); i++) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 1, deniedPrincipals_.getRaw(i));
- }
- for (int i = 0; i < exceptionPrincipals_.size(); i++) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 2, exceptionPrincipals_.getRaw(i));
- }
- for (int i = 0; i < deniedPermissions_.size(); i++) {
- com.google.protobuf.GeneratedMessageV3.writeString(output, 3, deniedPermissions_.getRaw(i));
- }
- for (int i = 0; i < exceptionPermissions_.size(); i++) {
- com.google.protobuf.GeneratedMessageV3.writeString(
- output, 4, exceptionPermissions_.getRaw(i));
- }
- if (denialCondition_ != null) {
- output.writeMessage(5, getDenialCondition());
- }
- getUnknownFields().writeTo(output);
- }
-
- @java.lang.Override
- public int getSerializedSize() {
- int size = memoizedSize;
- if (size != -1) return size;
-
- size = 0;
- {
- int dataSize = 0;
- for (int i = 0; i < deniedPrincipals_.size(); i++) {
- dataSize += computeStringSizeNoTag(deniedPrincipals_.getRaw(i));
- }
- size += dataSize;
- size += 1 * getDeniedPrincipalsList().size();
- }
- {
- int dataSize = 0;
- for (int i = 0; i < exceptionPrincipals_.size(); i++) {
- dataSize += computeStringSizeNoTag(exceptionPrincipals_.getRaw(i));
- }
- size += dataSize;
- size += 1 * getExceptionPrincipalsList().size();
- }
- {
- int dataSize = 0;
- for (int i = 0; i < deniedPermissions_.size(); i++) {
- dataSize += computeStringSizeNoTag(deniedPermissions_.getRaw(i));
- }
- size += dataSize;
- size += 1 * getDeniedPermissionsList().size();
- }
- {
- int dataSize = 0;
- for (int i = 0; i < exceptionPermissions_.size(); i++) {
- dataSize += computeStringSizeNoTag(exceptionPermissions_.getRaw(i));
- }
- size += dataSize;
- size += 1 * getExceptionPermissionsList().size();
- }
- if (denialCondition_ != null) {
- size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getDenialCondition());
- }
- size += getUnknownFields().getSerializedSize();
- memoizedSize = size;
- return size;
- }
-
- @java.lang.Override
- public boolean equals(final java.lang.Object obj) {
- if (obj == this) {
- return true;
- }
- if (!(obj instanceof com.google.iam.v2.DenyRule)) {
- return super.equals(obj);
- }
- com.google.iam.v2.DenyRule other = (com.google.iam.v2.DenyRule) obj;
-
- if (!getDeniedPrincipalsList().equals(other.getDeniedPrincipalsList())) return false;
- if (!getExceptionPrincipalsList().equals(other.getExceptionPrincipalsList())) return false;
- if (!getDeniedPermissionsList().equals(other.getDeniedPermissionsList())) return false;
- if (!getExceptionPermissionsList().equals(other.getExceptionPermissionsList())) return false;
- if (hasDenialCondition() != other.hasDenialCondition()) return false;
- if (hasDenialCondition()) {
- if (!getDenialCondition().equals(other.getDenialCondition())) return false;
- }
- if (!getUnknownFields().equals(other.getUnknownFields())) return false;
- return true;
- }
-
- @java.lang.Override
- public int hashCode() {
- if (memoizedHashCode != 0) {
- return memoizedHashCode;
- }
- int hash = 41;
- hash = (19 * hash) + getDescriptor().hashCode();
- if (getDeniedPrincipalsCount() > 0) {
- hash = (37 * hash) + DENIED_PRINCIPALS_FIELD_NUMBER;
- hash = (53 * hash) + getDeniedPrincipalsList().hashCode();
- }
- if (getExceptionPrincipalsCount() > 0) {
- hash = (37 * hash) + EXCEPTION_PRINCIPALS_FIELD_NUMBER;
- hash = (53 * hash) + getExceptionPrincipalsList().hashCode();
- }
- if (getDeniedPermissionsCount() > 0) {
- hash = (37 * hash) + DENIED_PERMISSIONS_FIELD_NUMBER;
- hash = (53 * hash) + getDeniedPermissionsList().hashCode();
- }
- if (getExceptionPermissionsCount() > 0) {
- hash = (37 * hash) + EXCEPTION_PERMISSIONS_FIELD_NUMBER;
- hash = (53 * hash) + getExceptionPermissionsList().hashCode();
- }
- if (hasDenialCondition()) {
- hash = (37 * hash) + DENIAL_CONDITION_FIELD_NUMBER;
- hash = (53 * hash) + getDenialCondition().hashCode();
- }
- hash = (29 * hash) + getUnknownFields().hashCode();
- memoizedHashCode = hash;
- return hash;
- }
-
- public static com.google.iam.v2.DenyRule parseFrom(java.nio.ByteBuffer data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v2.DenyRule parseFrom(
- java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v2.DenyRule parseFrom(com.google.protobuf.ByteString data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v2.DenyRule parseFrom(
- com.google.protobuf.ByteString data,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v2.DenyRule parseFrom(byte[] data)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data);
- }
-
- public static com.google.iam.v2.DenyRule parseFrom(
- byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws com.google.protobuf.InvalidProtocolBufferException {
- return PARSER.parseFrom(data, extensionRegistry);
- }
-
- public static com.google.iam.v2.DenyRule parseFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v2.DenyRule parseFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v2.DenyRule parseDelimitedFrom(java.io.InputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v2.DenyRule parseDelimitedFrom(
- java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- public static com.google.iam.v2.DenyRule parseFrom(com.google.protobuf.CodedInputStream input)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
- }
-
- public static com.google.iam.v2.DenyRule parseFrom(
- com.google.protobuf.CodedInputStream input,
- com.google.protobuf.ExtensionRegistryLite extensionRegistry)
- throws java.io.IOException {
- return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
- PARSER, input, extensionRegistry);
- }
-
- @java.lang.Override
- public Builder newBuilderForType() {
- return newBuilder();
- }
-
- public static Builder newBuilder() {
- return DEFAULT_INSTANCE.toBuilder();
- }
-
- public static Builder newBuilder(com.google.iam.v2.DenyRule prototype) {
- return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
- }
-
- @java.lang.Override
- public Builder toBuilder() {
- return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
- }
-
- @java.lang.Override
- protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
- Builder builder = new Builder(parent);
- return builder;
- }
- /**
- *
- *
- * - * A deny rule in an IAM deny policy. - *- * - * Protobuf type {@code google.iam.v2.DenyRule} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
- * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @return A list containing the deniedPrincipals.
- */
- public com.google.protobuf.ProtocolStringList getDeniedPrincipalsList() {
- return deniedPrincipals_.getUnmodifiableView();
- }
- /**
- *
- *
- * - * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @return The count of deniedPrincipals.
- */
- public int getDeniedPrincipalsCount() {
- return deniedPrincipals_.size();
- }
- /**
- *
- *
- * - * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @param index The index of the element to return.
- * @return The deniedPrincipals at the given index.
- */
- public java.lang.String getDeniedPrincipals(int index) {
- return deniedPrincipals_.get(index);
- }
- /**
- *
- *
- * - * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @param index The index of the value to return.
- * @return The bytes of the deniedPrincipals at the given index.
- */
- public com.google.protobuf.ByteString getDeniedPrincipalsBytes(int index) {
- return deniedPrincipals_.getByteString(index);
- }
- /**
- *
- *
- * - * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @param index The index to set the value at.
- * @param value The deniedPrincipals to set.
- * @return This builder for chaining.
- */
- public Builder setDeniedPrincipals(int index, java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureDeniedPrincipalsIsMutable();
- deniedPrincipals_.set(index, value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @param value The deniedPrincipals to add.
- * @return This builder for chaining.
- */
- public Builder addDeniedPrincipals(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureDeniedPrincipalsIsMutable();
- deniedPrincipals_.add(value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @param values The deniedPrincipals to add.
- * @return This builder for chaining.
- */
- public Builder addAllDeniedPrincipals(java.lang.Iterable- * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @return This builder for chaining.
- */
- public Builder clearDeniedPrincipals() {
- deniedPrincipals_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000001);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The identities that are prevented from using one or more permissions on - * Google Cloud resources. This field can contain the following values: - * * `principalSet://goog/public:all`: A special identifier that represents - * any principal that is on the internet, even if they do not have a Google - * Account or are not logged in. - * * `principal://goog/subject/{email_id}`: A specific Google Account. - * Includes Gmail, Cloud Identity, and Google Workspace user accounts. For - * example, `principal://goog/subject/alice@example.com`. - * * `deleted:principal://goog/subject/{email_id}?uid={uid}`: A specific - * Google Account that was deleted recently. For example, - * `deleted:principal://goog/subject/alice@example.com?uid=1234567890`. If - * the Google Account is recovered, this identifier reverts to the standard - * identifier for a Google Account. - * * `principalSet://goog/group/{group_id}`: A Google group. For example, - * `principalSet://goog/group/admins@example.com`. - * * `deleted:principalSet://goog/group/{group_id}?uid={uid}`: A Google group - * that was deleted recently. For example, - * `deleted:principalSet://goog/group/admins@example.com?uid=1234567890`. If - * the Google group is restored, this identifier reverts to the standard - * identifier for a Google group. - * * `principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}`: - * A Google Cloud service account. For example, - * `principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com`. - * * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/{service_account_id}?uid={uid}`: - * A Google Cloud service account that was deleted recently. For example, - * `deleted:principal://iam.googleapis.com/projects/-/serviceAccounts/my-service-account@iam.gserviceaccount.com?uid=1234567890`. - * If the service account is undeleted, this identifier reverts to the - * standard identifier for a service account. - * * `principalSet://goog/cloudIdentityCustomerId/{customer_id}`: All of the - * principals associated with the specified Google Workspace or Cloud - * Identity customer ID. For example, - * `principalSet://goog/cloudIdentityCustomerId/C01Abc35`. - *- * - *
repeated string denied_principals = 1;
- *
- * @param value The bytes of the deniedPrincipals to add.
- * @return This builder for chaining.
- */
- public Builder addDeniedPrincipalsBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
- ensureDeniedPrincipalsIsMutable();
- deniedPrincipals_.add(value);
- onChanged();
- return this;
- }
-
- private com.google.protobuf.LazyStringList exceptionPrincipals_ =
- com.google.protobuf.LazyStringArrayList.EMPTY;
-
- private void ensureExceptionPrincipalsIsMutable() {
- if (!((bitField0_ & 0x00000002) != 0)) {
- exceptionPrincipals_ = new com.google.protobuf.LazyStringArrayList(exceptionPrincipals_);
- bitField0_ |= 0x00000002;
- }
- }
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @return A list containing the exceptionPrincipals.
- */
- public com.google.protobuf.ProtocolStringList getExceptionPrincipalsList() {
- return exceptionPrincipals_.getUnmodifiableView();
- }
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @return The count of exceptionPrincipals.
- */
- public int getExceptionPrincipalsCount() {
- return exceptionPrincipals_.size();
- }
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @param index The index of the element to return.
- * @return The exceptionPrincipals at the given index.
- */
- public java.lang.String getExceptionPrincipals(int index) {
- return exceptionPrincipals_.get(index);
- }
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @param index The index of the value to return.
- * @return The bytes of the exceptionPrincipals at the given index.
- */
- public com.google.protobuf.ByteString getExceptionPrincipalsBytes(int index) {
- return exceptionPrincipals_.getByteString(index);
- }
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @param index The index to set the value at.
- * @param value The exceptionPrincipals to set.
- * @return This builder for chaining.
- */
- public Builder setExceptionPrincipals(int index, java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureExceptionPrincipalsIsMutable();
- exceptionPrincipals_.set(index, value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @param value The exceptionPrincipals to add.
- * @return This builder for chaining.
- */
- public Builder addExceptionPrincipals(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureExceptionPrincipalsIsMutable();
- exceptionPrincipals_.add(value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @param values The exceptionPrincipals to add.
- * @return This builder for chaining.
- */
- public Builder addAllExceptionPrincipals(java.lang.Iterable- * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @return This builder for chaining.
- */
- public Builder clearExceptionPrincipals() {
- exceptionPrincipals_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000002);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The identities that are excluded from the deny rule, even if they are - * listed in the `denied_principals`. For example, you could add a Google - * group to the `denied_principals`, then exclude specific users who belong to - * that group. - * This field can contain the same values as the `denied_principals` field, - * excluding `principalSet://goog/public:all`, which represents all users on - * the internet. - *- * - *
repeated string exception_principals = 2;
- *
- * @param value The bytes of the exceptionPrincipals to add.
- * @return This builder for chaining.
- */
- public Builder addExceptionPrincipalsBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
- ensureExceptionPrincipalsIsMutable();
- exceptionPrincipals_.add(value);
- onChanged();
- return this;
- }
-
- private com.google.protobuf.LazyStringList deniedPermissions_ =
- com.google.protobuf.LazyStringArrayList.EMPTY;
-
- private void ensureDeniedPermissionsIsMutable() {
- if (!((bitField0_ & 0x00000004) != 0)) {
- deniedPermissions_ = new com.google.protobuf.LazyStringArrayList(deniedPermissions_);
- bitField0_ |= 0x00000004;
- }
- }
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @return A list containing the deniedPermissions.
- */
- public com.google.protobuf.ProtocolStringList getDeniedPermissionsList() {
- return deniedPermissions_.getUnmodifiableView();
- }
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @return The count of deniedPermissions.
- */
- public int getDeniedPermissionsCount() {
- return deniedPermissions_.size();
- }
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @param index The index of the element to return.
- * @return The deniedPermissions at the given index.
- */
- public java.lang.String getDeniedPermissions(int index) {
- return deniedPermissions_.get(index);
- }
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @param index The index of the value to return.
- * @return The bytes of the deniedPermissions at the given index.
- */
- public com.google.protobuf.ByteString getDeniedPermissionsBytes(int index) {
- return deniedPermissions_.getByteString(index);
- }
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @param index The index to set the value at.
- * @param value The deniedPermissions to set.
- * @return This builder for chaining.
- */
- public Builder setDeniedPermissions(int index, java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureDeniedPermissionsIsMutable();
- deniedPermissions_.set(index, value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @param value The deniedPermissions to add.
- * @return This builder for chaining.
- */
- public Builder addDeniedPermissions(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureDeniedPermissionsIsMutable();
- deniedPermissions_.add(value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @param values The deniedPermissions to add.
- * @return This builder for chaining.
- */
- public Builder addAllDeniedPermissions(java.lang.Iterable- * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @return This builder for chaining.
- */
- public Builder clearDeniedPermissions() {
- deniedPermissions_ = com.google.protobuf.LazyStringArrayList.EMPTY;
- bitField0_ = (bitField0_ & ~0x00000004);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * The permissions that are explicitly denied by this rule. Each permission - * uses the format `{service_fqdn}/{resource}.{verb}`, where `{service_fqdn}` - * is the fully qualified domain name for the service. For example, - * `iam.googleapis.com/roles.list`. - *- * - *
repeated string denied_permissions = 3;
- *
- * @param value The bytes of the deniedPermissions to add.
- * @return This builder for chaining.
- */
- public Builder addDeniedPermissionsBytes(com.google.protobuf.ByteString value) {
- if (value == null) {
- throw new NullPointerException();
- }
- checkByteStringIsUtf8(value);
- ensureDeniedPermissionsIsMutable();
- deniedPermissions_.add(value);
- onChanged();
- return this;
- }
-
- private com.google.protobuf.LazyStringList exceptionPermissions_ =
- com.google.protobuf.LazyStringArrayList.EMPTY;
-
- private void ensureExceptionPermissionsIsMutable() {
- if (!((bitField0_ & 0x00000008) != 0)) {
- exceptionPermissions_ = new com.google.protobuf.LazyStringArrayList(exceptionPermissions_);
- bitField0_ |= 0x00000008;
- }
- }
- /**
- *
- *
- * - * Specifies the permissions that this rule excludes from the set of denied - * permissions given by `denied_permissions`. If a permission appears in - * `denied_permissions` _and_ in `exception_permissions` then it will _not_ be - * denied. - * The excluded permissions can be specified using the same syntax as - * `denied_permissions`. - *- * - *
repeated string exception_permissions = 4;
- *
- * @return A list containing the exceptionPermissions.
- */
- public com.google.protobuf.ProtocolStringList getExceptionPermissionsList() {
- return exceptionPermissions_.getUnmodifiableView();
- }
- /**
- *
- *
- * - * Specifies the permissions that this rule excludes from the set of denied - * permissions given by `denied_permissions`. If a permission appears in - * `denied_permissions` _and_ in `exception_permissions` then it will _not_ be - * denied. - * The excluded permissions can be specified using the same syntax as - * `denied_permissions`. - *- * - *
repeated string exception_permissions = 4;
- *
- * @return The count of exceptionPermissions.
- */
- public int getExceptionPermissionsCount() {
- return exceptionPermissions_.size();
- }
- /**
- *
- *
- * - * Specifies the permissions that this rule excludes from the set of denied - * permissions given by `denied_permissions`. If a permission appears in - * `denied_permissions` _and_ in `exception_permissions` then it will _not_ be - * denied. - * The excluded permissions can be specified using the same syntax as - * `denied_permissions`. - *- * - *
repeated string exception_permissions = 4;
- *
- * @param index The index of the element to return.
- * @return The exceptionPermissions at the given index.
- */
- public java.lang.String getExceptionPermissions(int index) {
- return exceptionPermissions_.get(index);
- }
- /**
- *
- *
- * - * Specifies the permissions that this rule excludes from the set of denied - * permissions given by `denied_permissions`. If a permission appears in - * `denied_permissions` _and_ in `exception_permissions` then it will _not_ be - * denied. - * The excluded permissions can be specified using the same syntax as - * `denied_permissions`. - *- * - *
repeated string exception_permissions = 4;
- *
- * @param index The index of the value to return.
- * @return The bytes of the exceptionPermissions at the given index.
- */
- public com.google.protobuf.ByteString getExceptionPermissionsBytes(int index) {
- return exceptionPermissions_.getByteString(index);
- }
- /**
- *
- *
- * - * Specifies the permissions that this rule excludes from the set of denied - * permissions given by `denied_permissions`. If a permission appears in - * `denied_permissions` _and_ in `exception_permissions` then it will _not_ be - * denied. - * The excluded permissions can be specified using the same syntax as - * `denied_permissions`. - *- * - *
repeated string exception_permissions = 4;
- *
- * @param index The index to set the value at.
- * @param value The exceptionPermissions to set.
- * @return This builder for chaining.
- */
- public Builder setExceptionPermissions(int index, java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureExceptionPermissionsIsMutable();
- exceptionPermissions_.set(index, value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies the permissions that this rule excludes from the set of denied - * permissions given by `denied_permissions`. If a permission appears in - * `denied_permissions` _and_ in `exception_permissions` then it will _not_ be - * denied. - * The excluded permissions can be specified using the same syntax as - * `denied_permissions`. - *- * - *
repeated string exception_permissions = 4;
- *
- * @param value The exceptionPermissions to add.
- * @return This builder for chaining.
- */
- public Builder addExceptionPermissions(java.lang.String value) {
- if (value == null) {
- throw new NullPointerException();
- }
- ensureExceptionPermissionsIsMutable();
- exceptionPermissions_.add(value);
- onChanged();
- return this;
- }
- /**
- *
- *
- * - * Specifies the permissions that this rule excludes from the set of denied - * permissions given by `denied_permissions`. If a permission appears in - * `denied_permissions` _and_ in `exception_permissions` then it will _not_ be - * denied. - * The excluded permissions can be specified using the same syntax as - * `denied_permissions`. - *- * - *
repeated string exception_permissions = 4;
- *
- * @param values The exceptionPermissions to add.
- * @return This builder for chaining.
- */
- public Builder addAllExceptionPermissions(java.lang.Iterable