Skip to content

Commit 3e27ca9

Browse files
feat: [common-protos] Add a proto message to describe the resource_type and resource_permission for an API method (#1878)
* feat: Add a proto message to describe the `resource_type` and `resource_permission` for an API method PiperOrigin-RevId: 550688034 Source-Link: googleapis/googleapis@52a738b Source-Link: https://github.com/googleapis/googleapis-gen/commit/a4242e487cb71adc5cbc5c356348b77ff477f03a Copy-Tag: eyJwIjoiamF2YS1jb21tb24tcHJvdG9zLy5Pd2xCb3QueWFtbCIsImgiOiJhNDI0MmU0ODdjYjcxYWRjNWNiYzVjMzU2MzQ4Yjc3ZmY0NzdmMDNhIn0= * feat: Add a proto message to describe the `resource_type` and `resource_permission` for an API method PiperOrigin-RevId: 550688034 Source-Link: googleapis/googleapis@52a738b Source-Link: https://github.com/googleapis/googleapis-gen/commit/a4242e487cb71adc5cbc5c356348b77ff477f03a Copy-Tag: eyJwIjoiamF2YS1jb21tb24tcHJvdG9zLy5Pd2xCb3QueWFtbCIsImgiOiJhNDI0MmU0ODdjYjcxYWRjNWNiYzVjMzU2MzQ4Yjc3ZmY0NzdmMDNhIn0= * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
1 parent 9d87ed3 commit 3e27ca9

File tree

10 files changed

+3239
-7
lines changed

10 files changed

+3239
-7
lines changed

java-common-protos/proto-google-common-protos/src/main/java/com/google/api/Control.java

+493
Large diffs are not rendered by default.

java-common-protos/proto-google-common-protos/src/main/java/com/google/api/ControlOrBuilder.java

+51
Original file line numberDiff line numberDiff line change
@@ -51,4 +51,55 @@ public interface ControlOrBuilder
5151
* @return The bytes for environment.
5252
*/
5353
com.google.protobuf.ByteString getEnvironmentBytes();
54+
55+
/**
56+
*
57+
*
58+
* <pre>
59+
* Defines policies applying to the API methods of the service.
60+
* </pre>
61+
*
62+
* <code>repeated .google.api.MethodPolicy method_policies = 4;</code>
63+
*/
64+
java.util.List<com.google.api.MethodPolicy> getMethodPoliciesList();
65+
/**
66+
*
67+
*
68+
* <pre>
69+
* Defines policies applying to the API methods of the service.
70+
* </pre>
71+
*
72+
* <code>repeated .google.api.MethodPolicy method_policies = 4;</code>
73+
*/
74+
com.google.api.MethodPolicy getMethodPolicies(int index);
75+
/**
76+
*
77+
*
78+
* <pre>
79+
* Defines policies applying to the API methods of the service.
80+
* </pre>
81+
*
82+
* <code>repeated .google.api.MethodPolicy method_policies = 4;</code>
83+
*/
84+
int getMethodPoliciesCount();
85+
/**
86+
*
87+
*
88+
* <pre>
89+
* Defines policies applying to the API methods of the service.
90+
* </pre>
91+
*
92+
* <code>repeated .google.api.MethodPolicy method_policies = 4;</code>
93+
*/
94+
java.util.List<? extends com.google.api.MethodPolicyOrBuilder> getMethodPoliciesOrBuilderList();
95+
/**
96+
*
97+
*
98+
* <pre>
99+
* Defines policies applying to the API methods of the service.
100+
* </pre>
101+
*
102+
* <code>repeated .google.api.MethodPolicy method_policies = 4;</code>
103+
*/
104+
com.google.api.MethodPolicyOrBuilder getMethodPoliciesOrBuilder(int index);
54105
}

java-common-protos/proto-google-common-protos/src/main/java/com/google/api/ControlProto.java

+13-7
Original file line numberDiff line numberDiff line change
@@ -40,22 +40,28 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
4040

4141
static {
4242
java.lang.String[] descriptorData = {
43-
"\n\030google/api/control.proto\022\ngoogle.api\"\036"
44-
+ "\n\007Control\022\023\n\013environment\030\001 \001(\tBn\n\016com.go"
45-
+ "ogle.apiB\014ControlProtoP\001ZEgoogle.golang."
46-
+ "org/genproto/googleapis/api/serviceconfi"
47-
+ "g;serviceconfig\242\002\004GAPIb\006proto3"
43+
"\n\030google/api/control.proto\022\ngoogle.api\032\027"
44+
+ "google/api/policy.proto\"Q\n\007Control\022\023\n\013en"
45+
+ "vironment\030\001 \001(\t\0221\n\017method_policies\030\004 \003(\013"
46+
+ "2\030.google.api.MethodPolicyBn\n\016com.google"
47+
+ ".apiB\014ControlProtoP\001ZEgoogle.golang.org/"
48+
+ "genproto/googleapis/api/serviceconfig;se"
49+
+ "rviceconfig\242\002\004GAPIb\006proto3"
4850
};
4951
descriptor =
5052
com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom(
51-
descriptorData, new com.google.protobuf.Descriptors.FileDescriptor[] {});
53+
descriptorData,
54+
new com.google.protobuf.Descriptors.FileDescriptor[] {
55+
com.google.api.PolicyProto.getDescriptor(),
56+
});
5257
internal_static_google_api_Control_descriptor = getDescriptor().getMessageTypes().get(0);
5358
internal_static_google_api_Control_fieldAccessorTable =
5459
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
5560
internal_static_google_api_Control_descriptor,
5661
new java.lang.String[] {
57-
"Environment",
62+
"Environment", "MethodPolicies",
5863
});
64+
com.google.api.PolicyProto.getDescriptor();
5965
}
6066

6167
// @@protoc_insertion_point(outer_class_scope)

0 commit comments

Comments
 (0)