public final class RelatedAsset extends GeneratedMessageV3 implements RelatedAssetOrBuilder
An asset identify in Google Cloud which contains its name, type and
ancestors. An asset can be any resource in the Google Cloud resource
hierarchy,
a resource outside the Google Cloud resource hierarchy (such as Google
Kubernetes Engine clusters and objects), or a policy (e.g. IAM policy).
See Supported asset
types
for more information.
Protobuf type google.cloud.asset.v1p7beta1.RelatedAsset
Inherited Members
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessageV3.<T>emptyList(java.lang.Class<T>)
Static Fields
public static final int ANCESTORS_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
public static final int ASSET_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
public static final int ASSET_TYPE_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
Static Methods
public static RelatedAsset getDefaultInstance()
public static final Descriptors.Descriptor getDescriptor()
public static RelatedAsset.Builder newBuilder()
public static RelatedAsset.Builder newBuilder(RelatedAsset prototype)
public static RelatedAsset parseDelimitedFrom(InputStream input)
public static RelatedAsset parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
public static RelatedAsset parseFrom(byte[] data)
Parameter |
Name |
Description |
data |
byte[]
|
public static RelatedAsset parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static RelatedAsset parseFrom(ByteString data)
public static RelatedAsset parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static RelatedAsset parseFrom(CodedInputStream input)
public static RelatedAsset parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public static RelatedAsset parseFrom(InputStream input)
public static RelatedAsset parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
public static RelatedAsset parseFrom(ByteBuffer data)
public static RelatedAsset parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static Parser<RelatedAsset> parser()
Methods
public boolean equals(Object obj)
Parameter |
Name |
Description |
obj |
Object
|
Overrides
public String getAncestors(int index)
The ancestors of an asset in Google Cloud resource
hierarchy,
represented as a list of relative resource names. An ancestry path starts
with the closest ancestor in the hierarchy and ends at root.
Example: ["projects/123456789", "folders/5432", "organizations/1234"]
repeated string ancestors = 3;
Parameter |
Name |
Description |
index |
int
The index of the element to return.
|
Returns |
Type |
Description |
String |
The ancestors at the given index.
|
public ByteString getAncestorsBytes(int index)
The ancestors of an asset in Google Cloud resource
hierarchy,
represented as a list of relative resource names. An ancestry path starts
with the closest ancestor in the hierarchy and ends at root.
Example: ["projects/123456789", "folders/5432", "organizations/1234"]
repeated string ancestors = 3;
Parameter |
Name |
Description |
index |
int
The index of the value to return.
|
Returns |
Type |
Description |
ByteString |
The bytes of the ancestors at the given index.
|
public int getAncestorsCount()
The ancestors of an asset in Google Cloud resource
hierarchy,
represented as a list of relative resource names. An ancestry path starts
with the closest ancestor in the hierarchy and ends at root.
Example: ["projects/123456789", "folders/5432", "organizations/1234"]
repeated string ancestors = 3;
Returns |
Type |
Description |
int |
The count of ancestors.
|
public ProtocolStringList getAncestorsList()
The ancestors of an asset in Google Cloud resource
hierarchy,
represented as a list of relative resource names. An ancestry path starts
with the closest ancestor in the hierarchy and ends at root.
Example: ["projects/123456789", "folders/5432", "organizations/1234"]
repeated string ancestors = 3;
The full name of the asset. Example:
//compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1
See Resource
names
for more information.
string asset = 1 [(.google.api.resource_reference) = { ... }
Returns |
Type |
Description |
String |
The asset.
|
public ByteString getAssetBytes()
The full name of the asset. Example:
//compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1
See Resource
names
for more information.
string asset = 1 [(.google.api.resource_reference) = { ... }
Returns |
Type |
Description |
ByteString |
The bytes for asset.
|
public String getAssetType()
The type of the asset. Example: compute.googleapis.com/Disk
See Supported asset
types
for more information.
string asset_type = 2;
Returns |
Type |
Description |
String |
The assetType.
|
public ByteString getAssetTypeBytes()
The type of the asset. Example: compute.googleapis.com/Disk
See Supported asset
types
for more information.
string asset_type = 2;
Returns |
Type |
Description |
ByteString |
The bytes for assetType.
|
public RelatedAsset getDefaultInstanceForType()
public Parser<RelatedAsset> getParserForType()
Overrides
public int getSerializedSize()
Returns |
Type |
Description |
int |
|
Overrides
Returns |
Type |
Description |
int |
|
Overrides
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
public final boolean isInitialized()
Overrides
public RelatedAsset.Builder newBuilderForType()
protected RelatedAsset.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Overrides
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Returns |
Type |
Description |
Object |
|
Overrides
public RelatedAsset.Builder toBuilder()
public void writeTo(CodedOutputStream output)
Overrides