Class Identity
- Namespace
- Cratis.Chronicle.Identities
- Assembly
- Cratis.Chronicle.dll
Represents an identity of something that is responsible for causing a state change.
public record Identity : IEquatable<Identity>
- Inheritance
-
Identity
- Implements
- Inherited Members
Remarks
An identity can be a user, a system, a service or anything else that can be identified.
Constructors
Identity(string, string, string, Identity?)
Represents an identity of something that is responsible for causing a state change.
public Identity(string Subject, string Name, string UserName = "", Identity? OnBehalfOf = null)
Parameters
Subject
stringThe identifier of the identity, referred to as subject.
Name
stringName of the identity.
UserName
stringOptional username, defaults to empty string.
OnBehalfOf
IdentityOptional behalf of Identity.
Remarks
An identity can be a user, a system, a service or anything else that can be identified.
Fields
NotSet
The identity used when not set.
public static readonly Identity NotSet
Field Value
System
The identity used when the system is the cause.
public static readonly Identity System
Field Value
Unknown
The identity used when the identity is not known.
public static readonly Identity Unknown
Field Value
Properties
Name
Name of the identity.
public string Name { get; init; }
Property Value
OnBehalfOf
Optional behalf of Identity.
public Identity? OnBehalfOf { get; init; }
Property Value
Subject
The identifier of the identity, referred to as subject.
public string Subject { get; init; }
Property Value
UserName
Optional username, defaults to empty string.
public string UserName { get; init; }