22.162. Class User
Namespace: ArmoniK.Core.Common.Injection.Options.Database
Assembly: ArmoniK.Core.Common.dll
Associate a User to its Roles
public record User : IEquatable<User>
22.162.1. Inheritance
22.162.2. Implements
22.162.3. Inherited Members
object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.MemberwiseClone(), object.ReferenceEquals(object?, object?), object.ToString()
22.162.4. Properties
22.162.4.1. Name
User Name
public required string Name { get; init; }
22.162.4.1.1. Property Value
22.162.4.2. Roles
Roles associated to the user
public required List<string> Roles { get; init; }
22.162.4.2.1. Property Value
22.162.5. Methods
22.162.5.1. Equals(User?)
Indicates whether the current object is equal to another object of the same type.
public virtual bool Equals(User? other)
22.162.5.1.1. Parameters
other User?
An object to compare with this object.
22.162.5.1.2. Returns
true if the current object is equal to the other parameter; otherwise, false.
22.162.5.2. FromJson(string)
Build a Associate a User to its Roles from a JSON Represents text as a sequence of UTF-16 code units.
public static User FromJson(string json)
22.162.5.2.1. Parameters
json string
JSON value
22.162.5.2.2. Returns
built from the provided JSON
22.162.5.3. GetHashCode()
Serves as the default hash function.
public override int GetHashCode()
22.162.5.3.1. Returns
A hash code for the current object.
22.162.5.4. ToJson()
Convert Associate a User to its Roles to JSON
public string ToJson()
22.162.5.4.1. Returns
representing the JSON object of this instance