Identity Access Context Manager v1 API - Class GcpUserAccessBindingName (2.4.0)

public sealed class GcpUserAccessBindingName : IResourceName, IEquatable<GcpUserAccessBindingName>

Reference documentation and code samples for the Identity Access Context Manager v1 API class GcpUserAccessBindingName.

Resource name for the GcpUserAccessBinding resource.

Inheritance

object > GcpUserAccessBindingName

Namespace

Google.Identity.AccessContextManager.V1

Assembly

Google.Identity.AccessContextManager.V1.dll

Constructors

GcpUserAccessBindingName(string, string)

public GcpUserAccessBindingName(string organizationId, string gcpUserAccessBindingId)

Constructs a new instance of a GcpUserAccessBindingName class from the component parts of pattern organizations/{organization}/gcpUserAccessBindings/{gcp_user_access_binding}

Parameters
Name Description
organizationId string

The Organization ID. Must not be null or empty.

gcpUserAccessBindingId string

The GcpUserAccessBinding ID. Must not be null or empty.

Properties

GcpUserAccessBindingId

public string GcpUserAccessBindingId { get; }

The GcpUserAccessBinding ID. Will not be null, unless this instance contains an unparsed resource name.

Property Value
Type Description
string

IsKnownPattern

public bool IsKnownPattern { get; }

Whether this instance contains a resource name with a known pattern.

Property Value
Type Description
bool

OrganizationId

public string OrganizationId { get; }

The Organization ID. Will not be null, unless this instance contains an unparsed resource name.

Property Value
Type Description
string

Type

public GcpUserAccessBindingName.ResourceNameType Type { get; }

The GcpUserAccessBindingName.ResourceNameType of the contained resource name.

Property Value
Type Description
GcpUserAccessBindingNameResourceNameType

UnparsedResource

public UnparsedResourceName UnparsedResource { get; }

The contained UnparsedResourceName. Only non-null if this instance contains an unparsed resource name.

Property Value
Type Description
UnparsedResourceName

Methods

Format(string, string)

public static string Format(string organizationId, string gcpUserAccessBindingId)

Formats the IDs into the string representation of this GcpUserAccessBindingName with pattern organizations/{organization}/gcpUserAccessBindings/{gcp_user_access_binding}.

Parameters
Name Description
organizationId string

The Organization ID. Must not be null or empty.

gcpUserAccessBindingId string

The GcpUserAccessBinding ID. Must not be null or empty.

Returns
Type Description
string

The string representation of this GcpUserAccessBindingName with pattern organizations/{organization}/gcpUserAccessBindings/{gcp_user_access_binding}.

FormatOrganizationGcpUserAccessBinding(string, string)

public static string FormatOrganizationGcpUserAccessBinding(string organizationId, string gcpUserAccessBindingId)

Formats the IDs into the string representation of this GcpUserAccessBindingName with pattern organizations/{organization}/gcpUserAccessBindings/{gcp_user_access_binding}.

Parameters
Name Description
organizationId string

The Organization ID. Must not be null or empty.

gcpUserAccessBindingId string

The GcpUserAccessBinding ID. Must not be null or empty.

Returns
Type Description
string

The string representation of this GcpUserAccessBindingName with pattern organizations/{organization}/gcpUserAccessBindings/{gcp_user_access_binding}.

FromOrganizationGcpUserAccessBinding(string, string)

public static GcpUserAccessBindingName FromOrganizationGcpUserAccessBinding(string organizationId, string gcpUserAccessBindingId)

Creates a GcpUserAccessBindingName with the pattern organizations/{organization}/gcpUserAccessBindings/{gcp_user_access_binding}.

Parameters
Name Description
organizationId string

The Organization ID. Must not be null or empty.

gcpUserAccessBindingId string

The GcpUserAccessBinding ID. Must not be null or empty.

Returns
Type Description
GcpUserAccessBindingName

A new instance of GcpUserAccessBindingName constructed from the provided ids.

FromUnparsed(UnparsedResourceName)

public static GcpUserAccessBindingName FromUnparsed(UnparsedResourceName unparsedResourceName)

Creates a GcpUserAccessBindingName containing an unparsed resource name.

Parameter
Name Description
unparsedResourceName UnparsedResourceName

The unparsed resource name. Must not be null.

Returns
Type Description
GcpUserAccessBindingName

A new instance of GcpUserAccessBindingName containing the provided unparsedResourceName.

GetHashCode()

public override int GetHashCode()

Returns a hash code for this resource name.

Returns
Type Description
int
Overrides

Parse(string)

public static GcpUserAccessBindingName Parse(string gcpUserAccessBindingName)

Parses the given resource name string into a new GcpUserAccessBindingName instance.

Parameter
Name Description
gcpUserAccessBindingName string

The resource name in string form. Must not be null.

Returns
Type Description
GcpUserAccessBindingName

The parsed GcpUserAccessBindingName if successful.

Remarks

To parse successfully, the resource name must be formatted as one of the following:

  • organizations/{organization}/gcpUserAccessBindings/{gcp_user_access_binding}

Parse(string, bool)

public static GcpUserAccessBindingName Parse(string gcpUserAccessBindingName, bool allowUnparsed)

Parses the given resource name string into a new GcpUserAccessBindingName instance; optionally allowing an unparseable resource name.

Parameters
Name Description
gcpUserAccessBindingName string

The resource name in string form. Must not be null.

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.

Returns
Type Description
GcpUserAccessBindingName

The parsed GcpUserAccessBindingName if successful.

Remarks

To parse successfully, the resource name must be formatted as one of the following:

  • organizations/{organization}/gcpUserAccessBindings/{gcp_user_access_binding}
Or may be in any format if allowUnparsed is true.

ToString()

public override string ToString()

The string representation of the resource name.

Returns
Type Description
string

The string representation of the resource name.

Overrides

TryParse(string, out GcpUserAccessBindingName)

public static bool TryParse(string gcpUserAccessBindingName, out GcpUserAccessBindingName result)

Tries to parse the given resource name string into a new GcpUserAccessBindingName instance.

Parameters
Name Description
gcpUserAccessBindingName string

The resource name in string form. Must not be null.

result GcpUserAccessBindingName

When this method returns, the parsed GcpUserAccessBindingName, or null if parsing failed.

Returns
Type Description
bool

true if the name was parsed successfully; false otherwise.

Remarks

To parse successfully, the resource name must be formatted as one of the following:

  • organizations/{organization}/gcpUserAccessBindings/{gcp_user_access_binding}

TryParse(string, bool, out GcpUserAccessBindingName)

public static bool TryParse(string gcpUserAccessBindingName, bool allowUnparsed, out GcpUserAccessBindingName result)

Tries to parse the given resource name string into a new GcpUserAccessBindingName instance; optionally allowing an unparseable resource name.

Parameters
Name Description
gcpUserAccessBindingName string

The resource name in string form. Must not be null.

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 GcpUserAccessBindingName

When this method returns, the parsed GcpUserAccessBindingName, or null if parsing failed.

Returns
Type Description
bool

true if the name was parsed successfully; false otherwise.

Remarks

To parse successfully, the resource name must be formatted as one of the following:

  • organizations/{organization}/gcpUserAccessBindings/{gcp_user_access_binding}
Or may be in any format if allowUnparsed is true.

Operators

operator ==(GcpUserAccessBindingName, GcpUserAccessBindingName)

public static bool operator ==(GcpUserAccessBindingName a, GcpUserAccessBindingName b)

Determines whether two specified resource names have the same value.

Parameters
Name Description
a GcpUserAccessBindingName

The first resource name to compare, or null.

b GcpUserAccessBindingName

The second resource name to compare, or null.

Returns
Type Description
bool

true if the value of a is the same as the value of b; otherwise, false.

operator !=(GcpUserAccessBindingName, GcpUserAccessBindingName)

public static bool operator !=(GcpUserAccessBindingName a, GcpUserAccessBindingName b)

Determines whether two specified resource names have different values.

Parameters
Name Description
a GcpUserAccessBindingName

The first resource name to compare, or null.

b GcpUserAccessBindingName

The second resource name to compare, or null.

Returns
Type Description
bool

true if the value of a is different from the value of b; otherwise, false.