diff --git a/google-cloud-asset/src/main/java/com/google/cloud/asset/v1/AssetServiceClient.java b/google-cloud-asset/src/main/java/com/google/cloud/asset/v1/AssetServiceClient.java index b65992096..85ee1c568 100644 --- a/google-cloud-asset/src/main/java/com/google/cloud/asset/v1/AssetServiceClient.java +++ b/google-cloud-asset/src/main/java/com/google/cloud/asset/v1/AssetServiceClient.java @@ -1138,6 +1138,9 @@ public final SearchAllResourcesPagedResponse searchAllResources( * the searchable fields (except for the included permissions). *
+ * The type of the resource associated with this IAM policy. Example: + * `compute.googleapis.com/Disk`. + * To search against the `asset_type`: + * * specify the `asset_types` field in your search request. + *+ * + *
string asset_type = 5;
+ *
+ * @return The assetType.
+ */
+ @java.lang.Override
+ public java.lang.String getAssetType() {
+ java.lang.Object ref = assetType_;
+ 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();
+ assetType_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * The type of the resource associated with this IAM policy. Example: + * `compute.googleapis.com/Disk`. + * To search against the `asset_type`: + * * specify the `asset_types` field in your search request. + *+ * + *
string asset_type = 5;
+ *
+ * @return The bytes for assetType.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getAssetTypeBytes() {
+ java.lang.Object ref = assetType_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ assetType_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
public static final int PROJECT_FIELD_NUMBER = 2;
private volatile java.lang.Object project_;
/**
@@ -2131,6 +2217,152 @@ public com.google.protobuf.ByteString getProjectBytes() {
}
}
+ public static final int FOLDERS_FIELD_NUMBER = 6;
+ private com.google.protobuf.LazyStringList folders_;
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @return A list containing the folders.
+ */
+ public com.google.protobuf.ProtocolStringList getFoldersList() {
+ return folders_;
+ }
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @return The count of folders.
+ */
+ public int getFoldersCount() {
+ return folders_.size();
+ }
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @param index The index of the element to return.
+ * @return The folders at the given index.
+ */
+ public java.lang.String getFolders(int index) {
+ return folders_.get(index);
+ }
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @param index The index of the value to return.
+ * @return The bytes of the folders at the given index.
+ */
+ public com.google.protobuf.ByteString getFoldersBytes(int index) {
+ return folders_.getByteString(index);
+ }
+
+ public static final int ORGANIZATION_FIELD_NUMBER = 7;
+ private volatile java.lang.Object organization_;
+ /**
+ *
+ *
+ * + * The organization that the IAM policy belongs to, in the form + * of organizations/{ORGANIZATION_NUMBER}. This field is available when the + * IAM policy belongs to an organization. + * To search against `organization`: + * * use a field query. Example: `organization:123` + * * use a free text query. Example: `123` + * * specify the `scope` field as this organization in your search request. + *+ * + *
string organization = 7;
+ *
+ * @return The organization.
+ */
+ @java.lang.Override
+ public java.lang.String getOrganization() {
+ java.lang.Object ref = organization_;
+ 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();
+ organization_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * The organization that the IAM policy belongs to, in the form + * of organizations/{ORGANIZATION_NUMBER}. This field is available when the + * IAM policy belongs to an organization. + * To search against `organization`: + * * use a field query. Example: `organization:123` + * * use a free text query. Example: `123` + * * specify the `scope` field as this organization in your search request. + *+ * + *
string organization = 7;
+ *
+ * @return The bytes for organization.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getOrganizationBytes() {
+ java.lang.Object ref = organization_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ organization_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
public static final int POLICY_FIELD_NUMBER = 3;
private com.google.iam.v1.Policy policy_;
/**
@@ -2288,6 +2520,15 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
if (explanation_ != null) {
output.writeMessage(4, getExplanation());
}
+ if (!getAssetTypeBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 5, assetType_);
+ }
+ for (int i = 0; i < folders_.size(); i++) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 6, folders_.getRaw(i));
+ }
+ if (!getOrganizationBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 7, organization_);
+ }
unknownFields.writeTo(output);
}
@@ -2309,6 +2550,20 @@ public int getSerializedSize() {
if (explanation_ != null) {
size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getExplanation());
}
+ if (!getAssetTypeBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, assetType_);
+ }
+ {
+ int dataSize = 0;
+ for (int i = 0; i < folders_.size(); i++) {
+ dataSize += computeStringSizeNoTag(folders_.getRaw(i));
+ }
+ size += dataSize;
+ size += 1 * getFoldersList().size();
+ }
+ if (!getOrganizationBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, organization_);
+ }
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
@@ -2326,7 +2581,10 @@ public boolean equals(final java.lang.Object obj) {
(com.google.cloud.asset.v1.IamPolicySearchResult) obj;
if (!getResource().equals(other.getResource())) return false;
+ if (!getAssetType().equals(other.getAssetType())) return false;
if (!getProject().equals(other.getProject())) return false;
+ if (!getFoldersList().equals(other.getFoldersList())) return false;
+ if (!getOrganization().equals(other.getOrganization())) return false;
if (hasPolicy() != other.hasPolicy()) return false;
if (hasPolicy()) {
if (!getPolicy().equals(other.getPolicy())) return false;
@@ -2348,8 +2606,16 @@ public int hashCode() {
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + RESOURCE_FIELD_NUMBER;
hash = (53 * hash) + getResource().hashCode();
+ hash = (37 * hash) + ASSET_TYPE_FIELD_NUMBER;
+ hash = (53 * hash) + getAssetType().hashCode();
hash = (37 * hash) + PROJECT_FIELD_NUMBER;
hash = (53 * hash) + getProject().hashCode();
+ if (getFoldersCount() > 0) {
+ hash = (37 * hash) + FOLDERS_FIELD_NUMBER;
+ hash = (53 * hash) + getFoldersList().hashCode();
+ }
+ hash = (37 * hash) + ORGANIZATION_FIELD_NUMBER;
+ hash = (53 * hash) + getOrganization().hashCode();
if (hasPolicy()) {
hash = (37 * hash) + POLICY_FIELD_NUMBER;
hash = (53 * hash) + getPolicy().hashCode();
@@ -2505,8 +2771,14 @@ public Builder clear() {
super.clear();
resource_ = "";
+ assetType_ = "";
+
project_ = "";
+ folders_ = com.google.protobuf.LazyStringArrayList.EMPTY;
+ bitField0_ = (bitField0_ & ~0x00000001);
+ organization_ = "";
+
if (policyBuilder_ == null) {
policy_ = null;
} else {
@@ -2546,8 +2818,16 @@ public com.google.cloud.asset.v1.IamPolicySearchResult build() {
public com.google.cloud.asset.v1.IamPolicySearchResult buildPartial() {
com.google.cloud.asset.v1.IamPolicySearchResult result =
new com.google.cloud.asset.v1.IamPolicySearchResult(this);
+ int from_bitField0_ = bitField0_;
result.resource_ = resource_;
+ result.assetType_ = assetType_;
result.project_ = project_;
+ if (((bitField0_ & 0x00000001) != 0)) {
+ folders_ = folders_.getUnmodifiableView();
+ bitField0_ = (bitField0_ & ~0x00000001);
+ }
+ result.folders_ = folders_;
+ result.organization_ = organization_;
if (policyBuilder_ == null) {
result.policy_ = policy_;
} else {
@@ -2612,10 +2892,28 @@ public Builder mergeFrom(com.google.cloud.asset.v1.IamPolicySearchResult other)
resource_ = other.resource_;
onChanged();
}
+ if (!other.getAssetType().isEmpty()) {
+ assetType_ = other.assetType_;
+ onChanged();
+ }
if (!other.getProject().isEmpty()) {
project_ = other.project_;
onChanged();
}
+ if (!other.folders_.isEmpty()) {
+ if (folders_.isEmpty()) {
+ folders_ = other.folders_;
+ bitField0_ = (bitField0_ & ~0x00000001);
+ } else {
+ ensureFoldersIsMutable();
+ folders_.addAll(other.folders_);
+ }
+ onChanged();
+ }
+ if (!other.getOrganization().isEmpty()) {
+ organization_ = other.organization_;
+ onChanged();
+ }
if (other.hasPolicy()) {
mergePolicy(other.getPolicy());
}
@@ -2651,6 +2949,8 @@ public Builder mergeFrom(
return this;
}
+ private int bitField0_;
+
private java.lang.Object resource_ = "";
/**
*
@@ -2792,6 +3092,127 @@ public Builder setResourceBytes(com.google.protobuf.ByteString value) {
return this;
}
+ private java.lang.Object assetType_ = "";
+ /**
+ *
+ *
+ * + * The type of the resource associated with this IAM policy. Example: + * `compute.googleapis.com/Disk`. + * To search against the `asset_type`: + * * specify the `asset_types` field in your search request. + *+ * + *
string asset_type = 5;
+ *
+ * @return The assetType.
+ */
+ public java.lang.String getAssetType() {
+ java.lang.Object ref = assetType_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ assetType_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The type of the resource associated with this IAM policy. Example: + * `compute.googleapis.com/Disk`. + * To search against the `asset_type`: + * * specify the `asset_types` field in your search request. + *+ * + *
string asset_type = 5;
+ *
+ * @return The bytes for assetType.
+ */
+ public com.google.protobuf.ByteString getAssetTypeBytes() {
+ java.lang.Object ref = assetType_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ assetType_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The type of the resource associated with this IAM policy. Example: + * `compute.googleapis.com/Disk`. + * To search against the `asset_type`: + * * specify the `asset_types` field in your search request. + *+ * + *
string asset_type = 5;
+ *
+ * @param value The assetType to set.
+ * @return This builder for chaining.
+ */
+ public Builder setAssetType(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ assetType_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The type of the resource associated with this IAM policy. Example: + * `compute.googleapis.com/Disk`. + * To search against the `asset_type`: + * * specify the `asset_types` field in your search request. + *+ * + *
string asset_type = 5;
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearAssetType() {
+
+ assetType_ = getDefaultInstance().getAssetType();
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The type of the resource associated with this IAM policy. Example: + * `compute.googleapis.com/Disk`. + * To search against the `asset_type`: + * * specify the `asset_types` field in your search request. + *+ * + *
string asset_type = 5;
+ *
+ * @param value The bytes for assetType to set.
+ * @return This builder for chaining.
+ */
+ public Builder setAssetTypeBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ assetType_ = value;
+ onChanged();
+ return this;
+ }
+
private java.lang.Object project_ = "";
/**
*
@@ -2928,6 +3349,364 @@ public Builder setProjectBytes(com.google.protobuf.ByteString value) {
return this;
}
+ private com.google.protobuf.LazyStringList folders_ =
+ com.google.protobuf.LazyStringArrayList.EMPTY;
+
+ private void ensureFoldersIsMutable() {
+ if (!((bitField0_ & 0x00000001) != 0)) {
+ folders_ = new com.google.protobuf.LazyStringArrayList(folders_);
+ bitField0_ |= 0x00000001;
+ }
+ }
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @return A list containing the folders.
+ */
+ public com.google.protobuf.ProtocolStringList getFoldersList() {
+ return folders_.getUnmodifiableView();
+ }
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @return The count of folders.
+ */
+ public int getFoldersCount() {
+ return folders_.size();
+ }
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @param index The index of the element to return.
+ * @return The folders at the given index.
+ */
+ public java.lang.String getFolders(int index) {
+ return folders_.get(index);
+ }
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @param index The index of the value to return.
+ * @return The bytes of the folders at the given index.
+ */
+ public com.google.protobuf.ByteString getFoldersBytes(int index) {
+ return folders_.getByteString(index);
+ }
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @param index The index to set the value at.
+ * @param value The folders to set.
+ * @return This builder for chaining.
+ */
+ public Builder setFolders(int index, java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureFoldersIsMutable();
+ folders_.set(index, value);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @param value The folders to add.
+ * @return This builder for chaining.
+ */
+ public Builder addFolders(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureFoldersIsMutable();
+ folders_.add(value);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @param values The folders to add.
+ * @return This builder for chaining.
+ */
+ public Builder addAllFolders(java.lang.Iterable+ * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearFolders() {
+ folders_ = com.google.protobuf.LazyStringArrayList.EMPTY;
+ bitField0_ = (bitField0_ & ~0x00000001);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @param value The bytes of the folders to add.
+ * @return This builder for chaining.
+ */
+ public Builder addFoldersBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+ ensureFoldersIsMutable();
+ folders_.add(value);
+ onChanged();
+ return this;
+ }
+
+ private java.lang.Object organization_ = "";
+ /**
+ *
+ *
+ * + * The organization that the IAM policy belongs to, in the form + * of organizations/{ORGANIZATION_NUMBER}. This field is available when the + * IAM policy belongs to an organization. + * To search against `organization`: + * * use a field query. Example: `organization:123` + * * use a free text query. Example: `123` + * * specify the `scope` field as this organization in your search request. + *+ * + *
string organization = 7;
+ *
+ * @return The organization.
+ */
+ public java.lang.String getOrganization() {
+ java.lang.Object ref = organization_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ organization_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The organization that the IAM policy belongs to, in the form + * of organizations/{ORGANIZATION_NUMBER}. This field is available when the + * IAM policy belongs to an organization. + * To search against `organization`: + * * use a field query. Example: `organization:123` + * * use a free text query. Example: `123` + * * specify the `scope` field as this organization in your search request. + *+ * + *
string organization = 7;
+ *
+ * @return The bytes for organization.
+ */
+ public com.google.protobuf.ByteString getOrganizationBytes() {
+ java.lang.Object ref = organization_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ organization_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The organization that the IAM policy belongs to, in the form + * of organizations/{ORGANIZATION_NUMBER}. This field is available when the + * IAM policy belongs to an organization. + * To search against `organization`: + * * use a field query. Example: `organization:123` + * * use a free text query. Example: `123` + * * specify the `scope` field as this organization in your search request. + *+ * + *
string organization = 7;
+ *
+ * @param value The organization to set.
+ * @return This builder for chaining.
+ */
+ public Builder setOrganization(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ organization_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The organization that the IAM policy belongs to, in the form + * of organizations/{ORGANIZATION_NUMBER}. This field is available when the + * IAM policy belongs to an organization. + * To search against `organization`: + * * use a field query. Example: `organization:123` + * * use a free text query. Example: `123` + * * specify the `scope` field as this organization in your search request. + *+ * + *
string organization = 7;
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearOrganization() {
+
+ organization_ = getDefaultInstance().getOrganization();
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The organization that the IAM policy belongs to, in the form + * of organizations/{ORGANIZATION_NUMBER}. This field is available when the + * IAM policy belongs to an organization. + * To search against `organization`: + * * use a field query. Example: `organization:123` + * * use a free text query. Example: `123` + * * specify the `scope` field as this organization in your search request. + *+ * + *
string organization = 7;
+ *
+ * @param value The bytes for organization to set.
+ * @return This builder for chaining.
+ */
+ public Builder setOrganizationBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ organization_ = value;
+ onChanged();
+ return this;
+ }
+
private com.google.iam.v1.Policy policy_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.iam.v1.Policy,
diff --git a/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/IamPolicySearchResultOrBuilder.java b/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/IamPolicySearchResultOrBuilder.java
index 8c5e8cefb..a79c38011 100644
--- a/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/IamPolicySearchResultOrBuilder.java
+++ b/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/IamPolicySearchResultOrBuilder.java
@@ -62,6 +62,37 @@ public interface IamPolicySearchResultOrBuilder
*/
com.google.protobuf.ByteString getResourceBytes();
+ /**
+ *
+ *
+ * + * The type of the resource associated with this IAM policy. Example: + * `compute.googleapis.com/Disk`. + * To search against the `asset_type`: + * * specify the `asset_types` field in your search request. + *+ * + *
string asset_type = 5;
+ *
+ * @return The assetType.
+ */
+ java.lang.String getAssetType();
+ /**
+ *
+ *
+ * + * The type of the resource associated with this IAM policy. Example: + * `compute.googleapis.com/Disk`. + * To search against the `asset_type`: + * * specify the `asset_types` field in your search request. + *+ * + *
string asset_type = 5;
+ *
+ * @return The bytes for assetType.
+ */
+ com.google.protobuf.ByteString getAssetTypeBytes();
+
/**
*
*
@@ -99,6 +130,118 @@ public interface IamPolicySearchResultOrBuilder
*/
com.google.protobuf.ByteString getProjectBytes();
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @return A list containing the folders.
+ */
+ java.util.List+ * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @return The count of folders.
+ */
+ int getFoldersCount();
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @param index The index of the element to return.
+ * @return The folders at the given index.
+ */
+ java.lang.String getFolders(int index);
+ /**
+ *
+ *
+ * + * The folder(s) that the IAM policy belongs to, in the form of + * folders/{FOLDER_NUMBER}. This field is available when the IAM policy + * belongs to one or more folders. + * To search against `folders`: + * * use a field query. Example: `folders:(123 OR 456)` + * * use a free text query. Example: `123` + * * specify the `scope` field as this folder in your search request. + *+ * + *
repeated string folders = 6;
+ *
+ * @param index The index of the value to return.
+ * @return The bytes of the folders at the given index.
+ */
+ com.google.protobuf.ByteString getFoldersBytes(int index);
+
+ /**
+ *
+ *
+ * + * The organization that the IAM policy belongs to, in the form + * of organizations/{ORGANIZATION_NUMBER}. This field is available when the + * IAM policy belongs to an organization. + * To search against `organization`: + * * use a field query. Example: `organization:123` + * * use a free text query. Example: `123` + * * specify the `scope` field as this organization in your search request. + *+ * + *
string organization = 7;
+ *
+ * @return The organization.
+ */
+ java.lang.String getOrganization();
+ /**
+ *
+ *
+ * + * The organization that the IAM policy belongs to, in the form + * of organizations/{ORGANIZATION_NUMBER}. This field is available when the + * IAM policy belongs to an organization. + * To search against `organization`: + * * use a field query. Example: `organization:123` + * * use a free text query. Example: `123` + * * specify the `scope` field as this organization in your search request. + *+ * + *
string organization = 7;
+ *
+ * @return The bytes for organization.
+ */
+ com.google.protobuf.ByteString getOrganizationBytes();
+
/**
*
*
diff --git a/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/SearchAllIamPoliciesRequest.java b/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/SearchAllIamPoliciesRequest.java
index 9ab7c271b..95f6d1c77 100644
--- a/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/SearchAllIamPoliciesRequest.java
+++ b/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/SearchAllIamPoliciesRequest.java
@@ -41,6 +41,8 @@ private SearchAllIamPoliciesRequest() {
scope_ = "";
query_ = "";
pageToken_ = "";
+ assetTypes_ = com.google.protobuf.LazyStringArrayList.EMPTY;
+ orderBy_ = "";
}
@java.lang.Override
@@ -62,6 +64,7 @@ private SearchAllIamPoliciesRequest(
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
+ int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
@@ -98,6 +101,23 @@ private SearchAllIamPoliciesRequest(
pageToken_ = s;
break;
}
+ case 42:
+ {
+ java.lang.String s = input.readStringRequireUtf8();
+ if (!((mutable_bitField0_ & 0x00000001) != 0)) {
+ assetTypes_ = new com.google.protobuf.LazyStringArrayList();
+ mutable_bitField0_ |= 0x00000001;
+ }
+ assetTypes_.add(s);
+ break;
+ }
+ case 58:
+ {
+ java.lang.String s = input.readStringRequireUtf8();
+
+ orderBy_ = s;
+ break;
+ }
default:
{
if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) {
@@ -112,6 +132,9 @@ private SearchAllIamPoliciesRequest(
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
} finally {
+ if (((mutable_bitField0_ & 0x00000001) != 0)) {
+ assetTypes_ = assetTypes_.getUnmodifiableView();
+ }
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
@@ -241,6 +264,10 @@ public com.google.protobuf.ByteString getScopeBytes() {
* * `resource:(instance1 OR instance2) policy:amy` to find
* IAM policy bindings that are set on resources "instance1" or
* "instance2" and also specify user "amy".
+ * * `roles:roles/compute.admin` to find IAM policy bindings that specify the
+ * Compute Admin role.
+ * * `memberTypes:user` to find IAM policy bindings that contain the "user"
+ * member type.
*
*
* string query = 2 [(.google.api.field_behavior) = OPTIONAL];
@@ -299,6 +326,10 @@ public java.lang.String getQuery() {
* * `resource:(instance1 OR instance2) policy:amy` to find
* IAM policy bindings that are set on resources "instance1" or
* "instance2" and also specify user "amy".
+ * * `roles:roles/compute.admin` to find IAM policy bindings that specify the
+ * Compute Admin role.
+ * * `memberTypes:user` to find IAM policy bindings that contain the "user"
+ * member type.
*
*
* string query = 2 [(.google.api.field_behavior) = OPTIONAL];
@@ -394,6 +425,182 @@ public com.google.protobuf.ByteString getPageTokenBytes() {
}
}
+ public static final int ASSET_TYPES_FIELD_NUMBER = 5;
+ private com.google.protobuf.LazyStringList assetTypes_;
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return A list containing the assetTypes.
+ */
+ public com.google.protobuf.ProtocolStringList getAssetTypesList() {
+ return assetTypes_;
+ }
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The count of assetTypes.
+ */
+ public int getAssetTypesCount() {
+ return assetTypes_.size();
+ }
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param index The index of the element to return.
+ * @return The assetTypes at the given index.
+ */
+ public java.lang.String getAssetTypes(int index) {
+ return assetTypes_.get(index);
+ }
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param index The index of the value to return.
+ * @return The bytes of the assetTypes at the given index.
+ */
+ public com.google.protobuf.ByteString getAssetTypesBytes(int index) {
+ return assetTypes_.getByteString(index);
+ }
+
+ public static final int ORDER_BY_FIELD_NUMBER = 7;
+ private volatile java.lang.Object orderBy_;
+ /**
+ *
+ *
+ * + * Optional. A comma-separated list of fields specifying the sorting order of the + * results. The default order is ascending. Add " DESC" after the field name + * to indicate descending order. Redundant space characters are ignored. + * Example: "assetType DESC, resource". + * Only singular primitive fields in the response are sortable: + * * resource + * * assetType + * * project + * All the other fields such as repeated fields (e.g., `folders`) and + * non-primitive fields (e.g., `policy`) are not supported. + *+ * + *
string order_by = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The orderBy.
+ */
+ @java.lang.Override
+ public java.lang.String getOrderBy() {
+ java.lang.Object ref = orderBy_;
+ 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();
+ orderBy_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. A comma-separated list of fields specifying the sorting order of the + * results. The default order is ascending. Add " DESC" after the field name + * to indicate descending order. Redundant space characters are ignored. + * Example: "assetType DESC, resource". + * Only singular primitive fields in the response are sortable: + * * resource + * * assetType + * * project + * All the other fields such as repeated fields (e.g., `folders`) and + * non-primitive fields (e.g., `policy`) are not supported. + *+ * + *
string order_by = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The bytes for orderBy.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getOrderByBytes() {
+ java.lang.Object ref = orderBy_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ orderBy_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
private byte memoizedIsInitialized = -1;
@java.lang.Override
@@ -420,6 +627,12 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
if (!getPageTokenBytes().isEmpty()) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 4, pageToken_);
}
+ for (int i = 0; i < assetTypes_.size(); i++) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 5, assetTypes_.getRaw(i));
+ }
+ if (!getOrderByBytes().isEmpty()) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 7, orderBy_);
+ }
unknownFields.writeTo(output);
}
@@ -441,6 +654,17 @@ public int getSerializedSize() {
if (!getPageTokenBytes().isEmpty()) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, pageToken_);
}
+ {
+ int dataSize = 0;
+ for (int i = 0; i < assetTypes_.size(); i++) {
+ dataSize += computeStringSizeNoTag(assetTypes_.getRaw(i));
+ }
+ size += dataSize;
+ size += 1 * getAssetTypesList().size();
+ }
+ if (!getOrderByBytes().isEmpty()) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, orderBy_);
+ }
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
@@ -461,6 +685,8 @@ public boolean equals(final java.lang.Object obj) {
if (!getQuery().equals(other.getQuery())) return false;
if (getPageSize() != other.getPageSize()) return false;
if (!getPageToken().equals(other.getPageToken())) return false;
+ if (!getAssetTypesList().equals(other.getAssetTypesList())) return false;
+ if (!getOrderBy().equals(other.getOrderBy())) return false;
if (!unknownFields.equals(other.unknownFields)) return false;
return true;
}
@@ -480,6 +706,12 @@ public int hashCode() {
hash = (53 * hash) + getPageSize();
hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER;
hash = (53 * hash) + getPageToken().hashCode();
+ if (getAssetTypesCount() > 0) {
+ hash = (37 * hash) + ASSET_TYPES_FIELD_NUMBER;
+ hash = (53 * hash) + getAssetTypesList().hashCode();
+ }
+ hash = (37 * hash) + ORDER_BY_FIELD_NUMBER;
+ hash = (53 * hash) + getOrderBy().hashCode();
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
@@ -634,6 +866,10 @@ public Builder clear() {
pageToken_ = "";
+ assetTypes_ = com.google.protobuf.LazyStringArrayList.EMPTY;
+ bitField0_ = (bitField0_ & ~0x00000001);
+ orderBy_ = "";
+
return this;
}
@@ -661,10 +897,17 @@ public com.google.cloud.asset.v1.SearchAllIamPoliciesRequest build() {
public com.google.cloud.asset.v1.SearchAllIamPoliciesRequest buildPartial() {
com.google.cloud.asset.v1.SearchAllIamPoliciesRequest result =
new com.google.cloud.asset.v1.SearchAllIamPoliciesRequest(this);
+ int from_bitField0_ = bitField0_;
result.scope_ = scope_;
result.query_ = query_;
result.pageSize_ = pageSize_;
result.pageToken_ = pageToken_;
+ if (((bitField0_ & 0x00000001) != 0)) {
+ assetTypes_ = assetTypes_.getUnmodifiableView();
+ bitField0_ = (bitField0_ & ~0x00000001);
+ }
+ result.assetTypes_ = assetTypes_;
+ result.orderBy_ = orderBy_;
onBuilt();
return result;
}
@@ -730,6 +973,20 @@ public Builder mergeFrom(com.google.cloud.asset.v1.SearchAllIamPoliciesRequest o
pageToken_ = other.pageToken_;
onChanged();
}
+ if (!other.assetTypes_.isEmpty()) {
+ if (assetTypes_.isEmpty()) {
+ assetTypes_ = other.assetTypes_;
+ bitField0_ = (bitField0_ & ~0x00000001);
+ } else {
+ ensureAssetTypesIsMutable();
+ assetTypes_.addAll(other.assetTypes_);
+ }
+ onChanged();
+ }
+ if (!other.getOrderBy().isEmpty()) {
+ orderBy_ = other.orderBy_;
+ onChanged();
+ }
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
@@ -760,6 +1017,8 @@ public Builder mergeFrom(
return this;
}
+ private int bitField0_;
+
private java.lang.Object scope_ = "";
/**
*
@@ -952,6 +1211,10 @@ public Builder setScopeBytes(com.google.protobuf.ByteString value) {
* * `resource:(instance1 OR instance2) policy:amy` to find
* IAM policy bindings that are set on resources "instance1" or
* "instance2" and also specify user "amy".
+ * * `roles:roles/compute.admin` to find IAM policy bindings that specify the
+ * Compute Admin role.
+ * * `memberTypes:user` to find IAM policy bindings that contain the "user"
+ * member type.
*
*
* string query = 2 [(.google.api.field_behavior) = OPTIONAL];
@@ -1009,6 +1272,10 @@ public java.lang.String getQuery() {
* * `resource:(instance1 OR instance2) policy:amy` to find
* IAM policy bindings that are set on resources "instance1" or
* "instance2" and also specify user "amy".
+ * * `roles:roles/compute.admin` to find IAM policy bindings that specify the
+ * Compute Admin role.
+ * * `memberTypes:user` to find IAM policy bindings that contain the "user"
+ * member type.
*
*
* string query = 2 [(.google.api.field_behavior) = OPTIONAL];
@@ -1066,6 +1333,10 @@ public com.google.protobuf.ByteString getQueryBytes() {
* * `resource:(instance1 OR instance2) policy:amy` to find
* IAM policy bindings that are set on resources "instance1" or
* "instance2" and also specify user "amy".
+ * * `roles:roles/compute.admin` to find IAM policy bindings that specify the
+ * Compute Admin role.
+ * * `memberTypes:user` to find IAM policy bindings that contain the "user"
+ * member type.
*
*
* string query = 2 [(.google.api.field_behavior) = OPTIONAL];
@@ -1122,6 +1393,10 @@ public Builder setQuery(java.lang.String value) {
* * `resource:(instance1 OR instance2) policy:amy` to find
* IAM policy bindings that are set on resources "instance1" or
* "instance2" and also specify user "amy".
+ * * `roles:roles/compute.admin` to find IAM policy bindings that specify the
+ * Compute Admin role.
+ * * `memberTypes:user` to find IAM policy bindings that contain the "user"
+ * member type.
*
*
* string query = 2 [(.google.api.field_behavior) = OPTIONAL];
@@ -1174,6 +1449,10 @@ public Builder clearQuery() {
* * `resource:(instance1 OR instance2) policy:amy` to find
* IAM policy bindings that are set on resources "instance1" or
* "instance2" and also specify user "amy".
+ * * `roles:roles/compute.admin` to find IAM policy bindings that specify the
+ * Compute Admin role.
+ * * `memberTypes:user` to find IAM policy bindings that contain the "user"
+ * member type.
*
*
* string query = 2 [(.google.api.field_behavior) = OPTIONAL];
@@ -1374,6 +1653,433 @@ public Builder setPageTokenBytes(com.google.protobuf.ByteString value) {
return this;
}
+ private com.google.protobuf.LazyStringList assetTypes_ =
+ com.google.protobuf.LazyStringArrayList.EMPTY;
+
+ private void ensureAssetTypesIsMutable() {
+ if (!((bitField0_ & 0x00000001) != 0)) {
+ assetTypes_ = new com.google.protobuf.LazyStringArrayList(assetTypes_);
+ bitField0_ |= 0x00000001;
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return A list containing the assetTypes.
+ */
+ public com.google.protobuf.ProtocolStringList getAssetTypesList() {
+ return assetTypes_.getUnmodifiableView();
+ }
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The count of assetTypes.
+ */
+ public int getAssetTypesCount() {
+ return assetTypes_.size();
+ }
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param index The index of the element to return.
+ * @return The assetTypes at the given index.
+ */
+ public java.lang.String getAssetTypes(int index) {
+ return assetTypes_.get(index);
+ }
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param index The index of the value to return.
+ * @return The bytes of the assetTypes at the given index.
+ */
+ public com.google.protobuf.ByteString getAssetTypesBytes(int index) {
+ return assetTypes_.getByteString(index);
+ }
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param index The index to set the value at.
+ * @param value The assetTypes to set.
+ * @return This builder for chaining.
+ */
+ public Builder setAssetTypes(int index, java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureAssetTypesIsMutable();
+ assetTypes_.set(index, value);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param value The assetTypes to add.
+ * @return This builder for chaining.
+ */
+ public Builder addAssetTypes(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureAssetTypesIsMutable();
+ assetTypes_.add(value);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param values The assetTypes to add.
+ * @return This builder for chaining.
+ */
+ public Builder addAllAssetTypes(java.lang.Iterable+ * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearAssetTypes() {
+ assetTypes_ = com.google.protobuf.LazyStringArrayList.EMPTY;
+ bitField0_ = (bitField0_ & ~0x00000001);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param value The bytes of the assetTypes to add.
+ * @return This builder for chaining.
+ */
+ public Builder addAssetTypesBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+ ensureAssetTypesIsMutable();
+ assetTypes_.add(value);
+ onChanged();
+ return this;
+ }
+
+ private java.lang.Object orderBy_ = "";
+ /**
+ *
+ *
+ * + * Optional. A comma-separated list of fields specifying the sorting order of the + * results. The default order is ascending. Add " DESC" after the field name + * to indicate descending order. Redundant space characters are ignored. + * Example: "assetType DESC, resource". + * Only singular primitive fields in the response are sortable: + * * resource + * * assetType + * * project + * All the other fields such as repeated fields (e.g., `folders`) and + * non-primitive fields (e.g., `policy`) are not supported. + *+ * + *
string order_by = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The orderBy.
+ */
+ public java.lang.String getOrderBy() {
+ java.lang.Object ref = orderBy_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ orderBy_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. A comma-separated list of fields specifying the sorting order of the + * results. The default order is ascending. Add " DESC" after the field name + * to indicate descending order. Redundant space characters are ignored. + * Example: "assetType DESC, resource". + * Only singular primitive fields in the response are sortable: + * * resource + * * assetType + * * project + * All the other fields such as repeated fields (e.g., `folders`) and + * non-primitive fields (e.g., `policy`) are not supported. + *+ * + *
string order_by = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The bytes for orderBy.
+ */
+ public com.google.protobuf.ByteString getOrderByBytes() {
+ java.lang.Object ref = orderBy_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ orderBy_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. A comma-separated list of fields specifying the sorting order of the + * results. The default order is ascending. Add " DESC" after the field name + * to indicate descending order. Redundant space characters are ignored. + * Example: "assetType DESC, resource". + * Only singular primitive fields in the response are sortable: + * * resource + * * assetType + * * project + * All the other fields such as repeated fields (e.g., `folders`) and + * non-primitive fields (e.g., `policy`) are not supported. + *+ * + *
string order_by = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param value The orderBy to set.
+ * @return This builder for chaining.
+ */
+ public Builder setOrderBy(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ orderBy_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. A comma-separated list of fields specifying the sorting order of the + * results. The default order is ascending. Add " DESC" after the field name + * to indicate descending order. Redundant space characters are ignored. + * Example: "assetType DESC, resource". + * Only singular primitive fields in the response are sortable: + * * resource + * * assetType + * * project + * All the other fields such as repeated fields (e.g., `folders`) and + * non-primitive fields (e.g., `policy`) are not supported. + *+ * + *
string order_by = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearOrderBy() {
+
+ orderBy_ = getDefaultInstance().getOrderBy();
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. A comma-separated list of fields specifying the sorting order of the + * results. The default order is ascending. Add " DESC" after the field name + * to indicate descending order. Redundant space characters are ignored. + * Example: "assetType DESC, resource". + * Only singular primitive fields in the response are sortable: + * * resource + * * assetType + * * project + * All the other fields such as repeated fields (e.g., `folders`) and + * non-primitive fields (e.g., `policy`) are not supported. + *+ * + *
string order_by = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param value The bytes for orderBy to set.
+ * @return This builder for chaining.
+ */
+ public Builder setOrderByBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ orderBy_ = value;
+ onChanged();
+ return this;
+ }
+
@java.lang.Override
public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
diff --git a/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/SearchAllIamPoliciesRequestOrBuilder.java b/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/SearchAllIamPoliciesRequestOrBuilder.java
index dfb8af0ad..b09fa81dd 100644
--- a/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/SearchAllIamPoliciesRequestOrBuilder.java
+++ b/proto-google-cloud-asset-v1/src/main/java/com/google/cloud/asset/v1/SearchAllIamPoliciesRequestOrBuilder.java
@@ -106,6 +106,10 @@ public interface SearchAllIamPoliciesRequestOrBuilder
* * `resource:(instance1 OR instance2) policy:amy` to find
* IAM policy bindings that are set on resources "instance1" or
* "instance2" and also specify user "amy".
+ * * `roles:roles/compute.admin` to find IAM policy bindings that specify the
+ * Compute Admin role.
+ * * `memberTypes:user` to find IAM policy bindings that contain the "user"
+ * member type.
*
*
* string query = 2 [(.google.api.field_behavior) = OPTIONAL];
@@ -153,6 +157,10 @@ public interface SearchAllIamPoliciesRequestOrBuilder
* * `resource:(instance1 OR instance2) policy:amy` to find
* IAM policy bindings that are set on resources "instance1" or
* "instance2" and also specify user "amy".
+ * * `roles:roles/compute.admin` to find IAM policy bindings that specify the
+ * Compute Admin role.
+ * * `memberTypes:user` to find IAM policy bindings that contain the "user"
+ * member type.
*
*
* string query = 2 [(.google.api.field_behavior) = OPTIONAL];
@@ -207,4 +215,146 @@ public interface SearchAllIamPoliciesRequestOrBuilder
* @return The bytes for pageToken.
*/
com.google.protobuf.ByteString getPageTokenBytes();
+
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return A list containing the assetTypes.
+ */
+ java.util.List+ * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The count of assetTypes.
+ */
+ int getAssetTypesCount();
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param index The index of the element to return.
+ * @return The assetTypes at the given index.
+ */
+ java.lang.String getAssetTypes(int index);
+ /**
+ *
+ *
+ * + * Optional. A list of asset types that the IAM policies are attached to. If empty, it + * will search the IAM policies that are attached to all the [searchable asset + * types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types). + * Regular expressions are also supported. For example: + * * "compute.googleapis.com.*" snapshots IAM policies attached to asset type + * starts with "compute.googleapis.com". + * * ".*Instance" snapshots IAM policies attached to asset type ends with + * "Instance". + * * ".*Instance.*" snapshots IAM policies attached to asset type contains + * "Instance". + * See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported + * regular expression syntax. If the regular expression does not match any + * supported asset type, an INVALID_ARGUMENT error will be returned. + *+ * + *
repeated string asset_types = 5 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @param index The index of the value to return.
+ * @return The bytes of the assetTypes at the given index.
+ */
+ com.google.protobuf.ByteString getAssetTypesBytes(int index);
+
+ /**
+ *
+ *
+ * + * Optional. A comma-separated list of fields specifying the sorting order of the + * results. The default order is ascending. Add " DESC" after the field name + * to indicate descending order. Redundant space characters are ignored. + * Example: "assetType DESC, resource". + * Only singular primitive fields in the response are sortable: + * * resource + * * assetType + * * project + * All the other fields such as repeated fields (e.g., `folders`) and + * non-primitive fields (e.g., `policy`) are not supported. + *+ * + *
string order_by = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The orderBy.
+ */
+ java.lang.String getOrderBy();
+ /**
+ *
+ *
+ * + * Optional. A comma-separated list of fields specifying the sorting order of the + * results. The default order is ascending. Add " DESC" after the field name + * to indicate descending order. Redundant space characters are ignored. + * Example: "assetType DESC, resource". + * Only singular primitive fields in the response are sortable: + * * resource + * * assetType + * * project + * All the other fields such as repeated fields (e.g., `folders`) and + * non-primitive fields (e.g., `policy`) are not supported. + *+ * + *
string order_by = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The bytes for orderBy.
+ */
+ com.google.protobuf.ByteString getOrderByBytes();
}
diff --git a/proto-google-cloud-asset-v1/src/main/proto/google/cloud/asset/v1/asset_service.proto b/proto-google-cloud-asset-v1/src/main/proto/google/cloud/asset/v1/asset_service.proto
index eadaef285..59f517bb0 100644
--- a/proto-google-cloud-asset-v1/src/main/proto/google/cloud/asset/v1/asset_service.proto
+++ b/proto-google-cloud-asset-v1/src/main/proto/google/cloud/asset/v1/asset_service.proto
@@ -838,6 +838,10 @@ message SearchAllIamPoliciesRequest {
// * `resource:(instance1 OR instance2) policy:amy` to find
// IAM policy bindings that are set on resources "instance1" or
// "instance2" and also specify user "amy".
+ // * `roles:roles/compute.admin` to find IAM policy bindings that specify the
+ // Compute Admin role.
+ // * `memberTypes:user` to find IAM policy bindings that contain the "user"
+ // member type.
string query = 2 [(google.api.field_behavior) = OPTIONAL];
// Optional. The page size for search result pagination. Page size is capped at 500 even
@@ -851,6 +855,36 @@ message SearchAllIamPoliciesRequest {
// previous response. The values of all other method parameters must be
// identical to those in the previous call.
string page_token = 4 [(google.api.field_behavior) = OPTIONAL];
+
+ // Optional. A list of asset types that the IAM policies are attached to. If empty, it
+ // will search the IAM policies that are attached to all the [searchable asset
+ // types](https://cloud.google.com/asset-inventory/docs/supported-asset-types#searchable_asset_types).
+ //
+ // Regular expressions are also supported. For example:
+ //
+ // * "compute.googleapis.com.*" snapshots IAM policies attached to asset type
+ // starts with "compute.googleapis.com".
+ // * ".*Instance" snapshots IAM policies attached to asset type ends with
+ // "Instance".
+ // * ".*Instance.*" snapshots IAM policies attached to asset type contains
+ // "Instance".
+ //
+ // See [RE2](https://github.com/google/re2/wiki/Syntax) for all supported
+ // regular expression syntax. If the regular expression does not match any
+ // supported asset type, an INVALID_ARGUMENT error will be returned.
+ repeated string asset_types = 5 [(google.api.field_behavior) = OPTIONAL];
+
+ // Optional. A comma-separated list of fields specifying the sorting order of the
+ // results. The default order is ascending. Add " DESC" after the field name
+ // to indicate descending order. Redundant space characters are ignored.
+ // Example: "assetType DESC, resource".
+ // Only singular primitive fields in the response are sortable:
+ // * resource
+ // * assetType
+ // * project
+ // All the other fields such as repeated fields (e.g., `folders`) and
+ // non-primitive fields (e.g., `policy`) are not supported.
+ string order_by = 7 [(google.api.field_behavior) = OPTIONAL];
}
// Search all IAM policies response.
diff --git a/proto-google-cloud-asset-v1/src/main/proto/google/cloud/asset/v1/assets.proto b/proto-google-cloud-asset-v1/src/main/proto/google/cloud/asset/v1/assets.proto
index 572ed739a..a607784e8 100644
--- a/proto-google-cloud-asset-v1/src/main/proto/google/cloud/asset/v1/assets.proto
+++ b/proto-google-cloud-asset-v1/src/main/proto/google/cloud/asset/v1/assets.proto
@@ -463,6 +463,14 @@ message IamPolicySearchResult {
// * use a field query. Example: `resource:organizations/123`
string resource = 1;
+ // The type of the resource associated with this IAM policy. Example:
+ // `compute.googleapis.com/Disk`.
+ //
+ // To search against the `asset_type`:
+ //
+ // * specify the `asset_types` field in your search request.
+ string asset_type = 5;
+
// The project that the associated GCP resource belongs to, in the form of
// projects/{PROJECT_NUMBER}. If an IAM policy is set on a resource (like VM
// instance, Cloud Storage bucket), the project field will indicate the
@@ -474,6 +482,28 @@ message IamPolicySearchResult {
// * specify the `scope` field as this project in your search request.
string project = 2;
+ // The folder(s) that the IAM policy belongs to, in the form of
+ // folders/{FOLDER_NUMBER}. This field is available when the IAM policy
+ // belongs to one or more folders.
+ //
+ // To search against `folders`:
+ //
+ // * use a field query. Example: `folders:(123 OR 456)`
+ // * use a free text query. Example: `123`
+ // * specify the `scope` field as this folder in your search request.
+ repeated string folders = 6;
+
+ // The organization that the IAM policy belongs to, in the form
+ // of organizations/{ORGANIZATION_NUMBER}. This field is available when the
+ // IAM policy belongs to an organization.
+ //
+ // To search against `organization`:
+ //
+ // * use a field query. Example: `organization:123`
+ // * use a free text query. Example: `123`
+ // * specify the `scope` field as this organization in your search request.
+ string organization = 7;
+
// The IAM policy directly set on the given resource. Note that the original
// IAM policy can contain multiple bindings. This only contains the bindings
// that match the given query. For queries that don't contain a constrain on