SaaS CMS has officially launched! Learn more now.

Class PrincipalExtensions

Provides extension methods for the System.Security.Principal.IPrincipal interface for getting contact information.

Inheritance
System.Object
PrincipalExtensions
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Mediachase.Commerce.Security
Assembly: Mediachase.Commerce.dll
Version: 11.8.3
Syntax
public static class PrincipalExtensions

Methods

GetContactId(IPrincipal)

Gets the CustomerContact identifier.

Declaration
public static Guid GetContactId(this IPrincipal principal)
Parameters
Type Name Description
System.Security.Principal.IPrincipal principal

The principal.

Returns
Type Description
System.Guid

Guid primary key for contact

GetCustomerContact(IPrincipal)

Gets the CustomerContact.

Declaration
public static CustomerContact GetCustomerContact(this IPrincipal principal)
Parameters
Type Name Description
System.Security.Principal.IPrincipal principal

The principal.

Returns
Type Description
CustomerContact

Current customer contact