public sealed class ColumnDataProfileName : IResourceName, IEquatable<ColumnDataProfileName>
Reference documentation and code samples for the Google Cloud Data Loss Prevention v2 API class ColumnDataProfileName.
Resource name for the ColumnDataProfile
resource.
Namespace
Google.Cloud.Dlp.V2Assembly
Google.Cloud.Dlp.V2.dll
Constructors
ColumnDataProfileName(string, string, string)
public ColumnDataProfileName(string organizationId, string locationId, string columnDataProfileId)
Constructs a new instance of a ColumnDataProfileName
class from the component parts of pattern organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}
Properties
ColumnDataProfileId
public string ColumnDataProfileId { get; }
The ColumnDataProfile
ID. May be null
, depending on which resource name is contained by this
instance.
IsKnownPattern
public bool IsKnownPattern { get; }
Whether this instance contains a resource name with a known pattern.
LocationId
public string LocationId { get; }
The Location
ID. May be null
, depending on which resource name is contained by this instance.
OrganizationId
public string OrganizationId { get; }
The Organization
ID. May be null
, depending on which resource name is contained by this
instance.
ProjectId
public string ProjectId { get; }
The Project
ID. May be null
, depending on which resource name is contained by this instance.
Type
public ColumnDataProfileName.ResourceNameType Type { get; }
The ColumnDataProfileName.ResourceNameType of the contained resource name.
UnparsedResource
public UnparsedResourceName UnparsedResource { get; }
The contained UnparsedResourceName
. Only non- null
if this instance contains an
unparsed resource name.
Methods
Format(string, string, string)
public static string Format(string organizationId, string locationId, string columnDataProfileId)
Formats the IDs into the string representation of this ColumnDataProfileName
with pattern organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}
.
The string representation of this ColumnDataProfileName
with pattern organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}
.
FormatOrganizationLocationColumnDataProfile(string, string, string)
public static string FormatOrganizationLocationColumnDataProfile(string organizationId, string locationId, string columnDataProfileId)
Formats the IDs into the string representation of this ColumnDataProfileName
with pattern organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}
.
The string representation of this ColumnDataProfileName
with pattern organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}
.
FormatProjectLocationColumnDataProfile(string, string, string)
public static string FormatProjectLocationColumnDataProfile(string projectId, string locationId, string columnDataProfileId)
Formats the IDs into the string representation of this ColumnDataProfileName
with pattern projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}
.
The string representation of this ColumnDataProfileName
with pattern projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}
.
FromOrganizationLocationColumnDataProfile(string, string, string)
public static ColumnDataProfileName FromOrganizationLocationColumnDataProfile(string organizationId, string locationId, string columnDataProfileId)
Creates a ColumnDataProfileName
with the pattern organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}
.
FromProjectLocationColumnDataProfile(string, string, string)
public static ColumnDataProfileName FromProjectLocationColumnDataProfile(string projectId, string locationId, string columnDataProfileId)
Creates a ColumnDataProfileName
with the pattern projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}
.
FromUnparsed(UnparsedResourceName)
public static ColumnDataProfileName FromUnparsed(UnparsedResourceName unparsedResourceName)
Creates a ColumnDataProfileName containing an unparsed resource name.
unparsedResourceName
A new instance of ColumnDataProfileName
containing the provided unparsedResourceName
.
GetHashCode()
public override int GetHashCode()
Returns a hash code for this resource name.
Parse(string)
public static ColumnDataProfileName Parse(string columnDataProfileName)
Parses the given resource name string into a new ColumnDataProfileName instance.
columnDataProfileName
To parse successfully, the resource name must be formatted as one of the following:
-
organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}
-
projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}
Parse(string, bool)
public static ColumnDataProfileName Parse(string columnDataProfileName, bool allowUnparsed)
Parses the given resource name string into a new ColumnDataProfileName instance; optionally allowing an unparseable resource name.
columnDataProfileName
allowUnparsed
bool
If true
will successfully store an unparseable resource name into the UnparsedResource
property; otherwise will throw an ArgumentException
if an unparseable resource name is
specified.
To parse successfully, the resource name must be formatted as one of the following:
-
organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}
-
projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}
allowUnparsed
is true
.ToString()
public override string ToString()
The string representation of the resource name.
TryParse(string, out ColumnDataProfileName)
public static bool TryParse(string columnDataProfileName, out ColumnDataProfileName result)
Tries to parse the given resource name string into a new ColumnDataProfileName instance.
columnDataProfileName
result
ColumnDataProfileName
When this method returns, the parsed ColumnDataProfileName
, or null
if parsing failed.
To parse successfully, the resource name must be formatted as one of the following:
-
organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}
-
projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}
TryParse(string, bool, out ColumnDataProfileName)
public static bool TryParse(string columnDataProfileName, bool allowUnparsed, out ColumnDataProfileName result)
Tries to parse the given resource name string into a new ColumnDataProfileName instance; optionally allowing an unparseable resource name.
columnDataProfileName
allowUnparsed
bool
If true
will successfully store an unparseable resource name into the UnparsedResource
property; otherwise will throw an ArgumentException
if an unparseable resource name is
specified.
result
ColumnDataProfileName
When this method returns, the parsed ColumnDataProfileName
, or null
if parsing failed.
To parse successfully, the resource name must be formatted as one of the following:
-
organizations/{organization}/locations/{location}/columnDataProfiles/{column_data_profile}
-
projects/{project}/locations/{location}/columnDataProfiles/{column_data_profile}
allowUnparsed
is true
.Operators
operator ==(ColumnDataProfileName, ColumnDataProfileName)
public static bool operator ==(ColumnDataProfileName a, ColumnDataProfileName b)
Determines whether two specified resource names have the same value.
a
b
true if the value of a
is the same as the value of b
; otherwise,
false.
operator !=(ColumnDataProfileName, ColumnDataProfileName)
public static bool operator !=(ColumnDataProfileName a, ColumnDataProfileName b)
Determines whether two specified resource names have different values.
a
b
true if the value of a
is different from the value of b
; otherwise,
false.