Options
Menu

This is a convenience class providing utilities to help identity a particular Domain User. A guid is the best means of uniquely identifing a user within a domain, which combines their userType with username.

DomainUserIds are read-only.

Hierarchy

  • DomainUserId

Index

Constructors

constructor

  • Constructs a DomainUserId from the given user type and username.

    Parameters

    • userType: DomainUserType

      the type of user

    • username: string

      the user's username

    Returns DomainUserId

Properties

userType

userType: DomainUserType

the type of user

username

username: string

the user's username

Methods

equals

  • Returns true if this user is the same as the given user.

    Parameters

    Returns boolean

toGuid

  • toGuid(): string
  • Returns a string GUID for this user guaranteed to be unique within this domain.

    Returns string

Staticanonymous

  • Constructs a "anonymous" DomainUserId by username.

    Parameters

    • username: string

      the anonymous unique users username.

    Returns DomainUserId

Staticguid

  • Constructs a GUID from the given user type and username.

    Equivalent to new DomainUserId(userType, username).toGuid()

    Parameters

    • userType: DomainUserType

      the type of user

    • username: string

      the user's username

    Returns string

Staticnormal

  • Constructs a "normal" DomainUserId by username.

    Parameters

    • username: string

      an existing DomainUser's username

    Returns DomainUserId

StatictoDomainUserId

  • This is a convenience function to construct a DomainUserId from a bare username.

    Parameters

    Returns DomainUserId