Class SfidIdOptions
Namespace: Cephalon.Ids.Sfid.Configuration
Assembly: Cephalon.Ids.Sfid.dll
Describes the host-owned configuration used to bootstrap the official Sfid.Net generator.
public sealed class SfidIdOptionsInheritance
Section titled “Inheritance”Inherited Members
Section titled “Inherited Members”object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.ReferenceEquals(object?, object?), object.ToString()
Constructors
Section titled “Constructors”SfidIdOptions(int?, int?, int?, int?)
Section titled “ SfidIdOptions(int?, int?, int?, int?)”Initializes a new instance of the
public SfidIdOptions(int? datacenterId = null, int? workerId = null, int? workerCapacity = null, int? clockRegressionToleranceMilliseconds = null)Parameters
Section titled “Parameters”datacenterId int?
The datacenter identifier supplied to the generator.
workerId int?
The worker identifier supplied to the generator.
workerCapacity int?
The optional worker-capacity override supplied to the generator.
clockRegressionToleranceMilliseconds int?
The optional clock-regression tolerance, in milliseconds, supplied to the generator.
Fields
Section titled “Fields”DefaultSectionPath
Section titled “ DefaultSectionPath”Gets the default configuration path used by the Sfid id-strategy pack.
public const string DefaultSectionPath = "Engine:Data:Ids:Sfid"Field Value
Section titled “Field Value”Properties
Section titled “Properties”ClockRegressionToleranceMilliseconds
Section titled “ ClockRegressionToleranceMilliseconds”Gets the optional clock-regression tolerance, in milliseconds, supplied to the generator.
public int? ClockRegressionToleranceMilliseconds { get; set; }Property Value
Section titled “Property Value”int?
DatacenterId
Section titled “ DatacenterId”Gets the datacenter identifier supplied to the generator.
public int? DatacenterId { get; set; }Property Value
Section titled “Property Value”int?
Gets an empty options instance.
public static SfidIdOptions Empty { get; }Property Value
Section titled “Property Value”HasValues
Section titled “ HasValues”Gets a value indicating whether any explicit Sfid-generator inputs were supplied.
public bool HasValues { get; }Property Value
Section titled “Property Value”WorkerCapacity
Section titled “ WorkerCapacity”Gets the optional worker-capacity override supplied to the generator.
public int? WorkerCapacity { get; set; }Property Value
Section titled “Property Value”int?
WorkerId
Section titled “ WorkerId”Gets the worker identifier supplied to the generator.
public int? WorkerId { get; set; }Property Value
Section titled “Property Value”int?
Methods
Section titled “Methods”FromConfiguration(IConfiguration?, string)
Section titled “ FromConfiguration(IConfiguration?, string)”Reads Sfid id-strategy options from configuration.
public static SfidIdOptions FromConfiguration(IConfiguration? configuration, string sectionPath = "Engine:Data:Ids:Sfid")Parameters
Section titled “Parameters”configuration IConfiguration?
The configuration root to read.
sectionPath string
The configuration path that contains the Sfid id-strategy settings. The default is Engine:Data:Ids:Sfid.
Returns
Section titled “Returns”The parsed options.