Send feedback
Class PolicyTag (1.23.0)
Stay organized with collections
Save and categorize content based on your preferences.
Version 1.23.0 keyboard_arrow_down
public final class PolicyTag extends GeneratedMessageV3 implements PolicyTagOrBuilder
Denotes one policy tag in a taxonomy, for example, SSN.
Policy tags can be defined in a hierarchy. For example:
`
`
Where the "Geolocation" policy tag contains three children.
Protobuf type google.cloud.datacatalog.v1.PolicyTag
Static Fields
public static final int CHILD_POLICY_TAGS_FIELD_NUMBER
Field Value Type Description int
DESCRIPTION_FIELD_NUMBER
public static final int DESCRIPTION_FIELD_NUMBER
Field Value Type Description int
DISPLAY_NAME_FIELD_NUMBER
public static final int DISPLAY_NAME_FIELD_NUMBER
Field Value Type Description int
NAME_FIELD_NUMBER
public static final int NAME_FIELD_NUMBER
Field Value Type Description int
PARENT_POLICY_TAG_FIELD_NUMBER
public static final int PARENT_POLICY_TAG_FIELD_NUMBER
Field Value Type Description int
Static Methods
getDefaultInstance()
public static PolicyTag getDefaultInstance ()
getDescriptor()
public static final Descriptors . Descriptor getDescriptor ()
newBuilder()
public static PolicyTag . Builder newBuilder ()
newBuilder(PolicyTag prototype)
public static PolicyTag . Builder newBuilder ( PolicyTag prototype )
public static PolicyTag parseDelimitedFrom ( InputStream input )
public static PolicyTag parseDelimitedFrom ( InputStream input , ExtensionRegistryLite extensionRegistry )
parseFrom(byte[] data)
public static PolicyTag parseFrom ( byte [] data )
Parameter Name Description data
byte []
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static PolicyTag parseFrom ( byte [] data , ExtensionRegistryLite extensionRegistry )
parseFrom(ByteString data)
public static PolicyTag parseFrom ( ByteString data )
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static PolicyTag parseFrom ( ByteString data , ExtensionRegistryLite extensionRegistry )
public static PolicyTag parseFrom ( CodedInputStream input )
public static PolicyTag parseFrom ( CodedInputStream input , ExtensionRegistryLite extensionRegistry )
public static PolicyTag parseFrom ( InputStream input )
public static PolicyTag parseFrom ( InputStream input , ExtensionRegistryLite extensionRegistry )
parseFrom(ByteBuffer data)
public static PolicyTag parseFrom ( ByteBuffer data )
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static PolicyTag parseFrom ( ByteBuffer data , ExtensionRegistryLite extensionRegistry )
parser()
public static Parser<PolicyTag> parser ()
Methods
equals(Object obj)
public boolean equals ( Object obj )
Parameter Name Description obj
Object
Overrides
public String getChildPolicyTags ( int index )
Output only. Resource names of child policy tags of this policy tag.
repeated string child_policy_tags = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter Name Description index
int
The index of the element to return.
Returns Type Description String
The childPolicyTags at the given index.
public ByteString getChildPolicyTagsBytes ( int index )
Output only. Resource names of child policy tags of this policy tag.
repeated string child_policy_tags = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter Name Description index
int
The index of the value to return.
Returns Type Description ByteString
The bytes of the childPolicyTags at the given index.
public int getChildPolicyTagsCount ()
Output only. Resource names of child policy tags of this policy tag.
repeated string child_policy_tags = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns Type Description int
The count of childPolicyTags.
public ProtocolStringList getChildPolicyTagsList ()
Output only. Resource names of child policy tags of this policy tag.
repeated string child_policy_tags = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
getDefaultInstanceForType()
public PolicyTag getDefaultInstanceForType ()
getDescription()
public String getDescription ()
Description of this policy tag. If not set, defaults to empty.
The description must contain only Unicode characters,
tabs, newlines, carriage returns and page breaks, and be at most 2000 bytes
long when encoded in UTF-8.
string description = 3;
Returns Type Description String
The description.
getDescriptionBytes()
public ByteString getDescriptionBytes ()
Description of this policy tag. If not set, defaults to empty.
The description must contain only Unicode characters,
tabs, newlines, carriage returns and page breaks, and be at most 2000 bytes
long when encoded in UTF-8.
string description = 3;
Returns Type Description ByteString
The bytes for description.
getDisplayName()
public String getDisplayName ()
Required. User-defined name of this policy tag.
The name can't start or end with spaces and must be unique within the
parent taxonomy, contain only Unicode letters, numbers, underscores, dashes
and spaces, and be at most 200 bytes long when encoded in UTF-8.
string display_name = 2 [(.google.api.field_behavior) = REQUIRED];
Returns Type Description String
The displayName.
getDisplayNameBytes()
public ByteString getDisplayNameBytes ()
Required. User-defined name of this policy tag.
The name can't start or end with spaces and must be unique within the
parent taxonomy, contain only Unicode letters, numbers, underscores, dashes
and spaces, and be at most 200 bytes long when encoded in UTF-8.
string display_name = 2 [(.google.api.field_behavior) = REQUIRED];
Returns Type Description ByteString
The bytes for displayName.
getName()
Output only. Resource name of this policy tag in the URL format.
The policy tag manager generates unique taxonomy IDs and policy tag IDs.
string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns Type Description String
The name.
getNameBytes()
public ByteString getNameBytes ()
Output only. Resource name of this policy tag in the URL format.
The policy tag manager generates unique taxonomy IDs and policy tag IDs.
string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns Type Description ByteString
The bytes for name.
getParentPolicyTag()
public String getParentPolicyTag ()
Resource name of this policy tag's parent policy tag. If empty, this is a
top level tag. If not set, defaults to an empty string.
For example, for the "LatLong" policy tag in the example above, this field
contains the resource name of the "Geolocation" policy tag, and, for
"Geolocation", this field is empty.
string parent_policy_tag = 4;
Returns Type Description String
The parentPolicyTag.
getParentPolicyTagBytes()
public ByteString getParentPolicyTagBytes ()
Resource name of this policy tag's parent policy tag. If empty, this is a
top level tag. If not set, defaults to an empty string.
For example, for the "LatLong" policy tag in the example above, this field
contains the resource name of the "Geolocation" policy tag, and, for
"Geolocation", this field is empty.
string parent_policy_tag = 4;
Returns Type Description ByteString
The bytes for parentPolicyTag.
getParserForType()
public Parser<PolicyTag> getParserForType ()
Overrides
getSerializedSize()
public int getSerializedSize ()
Returns Type Description int
Overrides
getUnknownFields()
public final UnknownFieldSet getUnknownFields ()
Overrides
hashCode()
Returns Type Description int
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3 . FieldAccessorTable internalGetFieldAccessorTable ()
Overrides
isInitialized()
public final boolean isInitialized ()
Overrides
newBuilderForType()
public PolicyTag . Builder newBuilderForType ()
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected PolicyTag . Builder newBuilderForType ( GeneratedMessageV3 . BuilderParent parent )
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance ( GeneratedMessageV3 . UnusedPrivateParameter unused )
Overrides
toBuilder()
public PolicyTag . Builder toBuilder ()
writeTo(CodedOutputStream output)
public void writeTo ( CodedOutputStream output )
Overrides
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-01-28 UTC.
Need to tell us more?
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-01-28 UTC."],[],[]]