Table of Contents

Class SharedAccessAuthorizationRule

Namespace
Microsoft.Azure.ServiceBus.Management
Assembly
Microsoft.Azure.ServiceBus.dll

Defines the authorization rule for an entity using SAS.

public class SharedAccessAuthorizationRule : AuthorizationRule, IEquatable<AuthorizationRule>
Inheritance
SharedAccessAuthorizationRule
Implements
Inherited Members

Constructors

SharedAccessAuthorizationRule(string, IEnumerable<AccessRights>)

Initializes a new instance of the SharedAccessAuthorizationRule class.

public SharedAccessAuthorizationRule(string keyName, IEnumerable<AccessRights> rights)

Parameters

keyName string

The authorization rule key name.

rights IEnumerable<AccessRights>

The list of rights.

SharedAccessAuthorizationRule(string, string, IEnumerable<AccessRights>)

Initializes a new instance of the SharedAccessAuthorizationRule class.

public SharedAccessAuthorizationRule(string keyName, string primaryKey, IEnumerable<AccessRights> rights)

Parameters

keyName string

The authorization rule key name.

primaryKey string

The primary key for the authorization rule.

rights IEnumerable<AccessRights>

The list of rights.

SharedAccessAuthorizationRule(string, string, string, IEnumerable<AccessRights>)

Initializes a new instance of the SharedAccessAuthorizationRule class.

public SharedAccessAuthorizationRule(string keyName, string primaryKey, string secondaryKey, IEnumerable<AccessRights> rights)

Parameters

keyName string

The authorization rule key name.

primaryKey string

The primary key for the authorization rule.

secondaryKey string

The secondary key for the authorization rule.

rights IEnumerable<AccessRights>

The list of rights.

Properties

ClaimType

Gets or sets the claim type.

public override string ClaimType { get; }

Property Value

string

The claim type.

KeyName

Gets or sets the authorization rule key name.

public override sealed string KeyName { get; set; }

Property Value

string

The authorization rule key name.

PrimaryKey

Gets or sets the primary key for the authorization rule.

public string PrimaryKey { get; set; }

Property Value

string

The primary key for the authorization rule.

Rights

Gets or sets the list of rights.

public override List<AccessRights> Rights { get; set; }

Property Value

List<AccessRights>

The list of rights.

SecondaryKey

Gets or sets the secondary key for the authorization rule.

public string SecondaryKey { get; set; }

Property Value

string

The secondary key for the authorization rule.

Methods

Equals(AuthorizationRule)

Determines whether the specified object is equal to the current object.

public override bool Equals(AuthorizationRule other)

Parameters

other AuthorizationRule

The object to compare with the current object.

Returns

bool

true if the specified object is equal to the current object; otherwise, false.

Equals(object)

public override bool Equals(object obj)

Parameters

obj object

Returns

bool

GetHashCode()

Returns the hash code for this instance.

public override int GetHashCode()

Returns

int

Operators

operator ==(SharedAccessAuthorizationRule, SharedAccessAuthorizationRule)

public static bool operator ==(SharedAccessAuthorizationRule o1, SharedAccessAuthorizationRule o2)

Parameters

o1 SharedAccessAuthorizationRule
o2 SharedAccessAuthorizationRule

Returns

bool

operator !=(SharedAccessAuthorizationRule, SharedAccessAuthorizationRule)

public static bool operator !=(SharedAccessAuthorizationRule o1, SharedAccessAuthorizationRule o2)

Parameters

o1 SharedAccessAuthorizationRule
o2 SharedAccessAuthorizationRule

Returns

bool