public ErrorCode(IErrorCode other, ArgumentPlaceholder <string> description = default, ArgumentPlaceholder <SeverityLevel?> severityLevel = default) : this( identifier : other.EnsureNotNull(nameof(other)).Value.Identifier, severityLevel : severityLevel.Substitute(value : other.SeverityLevel), description : description.Substitute(value : other.Description)) { }
public TriggerSignalProperties(ITrigger trigger, ITriggerSignalProperties source, ArgumentPlaceholder <DateTimeOffset> timestamp = default) { trigger.EnsureNotNull(nameof(trigger)); source.EnsureNotNull(nameof(source)); // _trigger = trigger; _source = source; _timestamp = timestamp.Substitute(value: source.Timestamp); _correlationId = source.CorrelationId; _explicitlyDefinedProps = timestamp.HasExplicitValue ? ExplicitlyDefinedProps.Timestamp : ExplicitlyDefinedProps.None; }
public TriggerSignalProperties(ITrigger trigger, ArgumentPlaceholder <DateTimeOffset> timestamp = default, ArgumentPlaceholder <XFullCorrelationId> correlationId = default) { trigger.EnsureNotNull(nameof(trigger)); if (correlationId.HasExplicitValue && correlationId.ExplicitValue.IsEmpty) { throw new ArgumentException(message: "Cannot be empty.", paramName: nameof(correlationId)); } // _trigger = trigger; _source = null; _timestamp = timestamp.Substitute(value: DateTimeOffset.Now); _correlationId = correlationId.Substitute(value: default);
public Pool( Func <T> itemFactory, ArgumentPlaceholder <bool> ownsItem = default, ArgumentPlaceholder <TimeoutDuration> itemPreferredSlidingTtl = default, ArgumentPlaceholder <int> maxSize = default, string displayName = default, ArgumentPlaceholder <ILogger> logger = default) : this( itemFactory : P_MakeItemFactoryDelegate(itemFactory : itemFactory), ownsItem : ownsItem.Substitute(value : Pool.DefaultOfOwnsItem), itemPreferredSlidingTtl : itemPreferredSlidingTtl.Substitute(value : Pool.DefaultOfItemPreferredSlidingTtl), maxSize : maxSize.Substitute(value : Pool.DefaultOfMaxSize), displayName : displayName, logger : logger) { }
internal P_State( P_State other, ArgumentPlaceholder <bool> initializationDone = default, ArgumentPlaceholder <IDbContextTransaction> realTx = default, ArgumentPlaceholder <Action <PersistenceEfCoreDataContextTxScope> > disposeCallback = default, ArgumentPlaceholder <Action <PersistenceEfCoreDataContextTxScope> > completeCallback = default, ArgumentPlaceholder <bool> shouldRollback = default, ArgumentPlaceholder <bool> commitIntention = default, ArgumentPlaceholder <bool> finishingStart = default) { // InitializationDone = initializationDone.Substitute(other.InitializationDone); RealTx = realTx.Substitute(other.RealTx); DisposeCallback = disposeCallback.Substitute(other.DisposeCallback); CompleteCallback = completeCallback.Substitute(other.CompleteCallback); ShouldRollback = shouldRollback.Substitute(other.ShouldRollback); CommitIntention = commitIntention.Substitute(other.CommitIntention); FinishingStart = finishingStart.Substitute(other.FinishingStart); }
internal RunControlAttemptSuccess(IRunControlAttemptSuccess other, ArgumentPlaceholder <bool> isMaster = default) : this(props : other.EnsureNotNull(nameof(other)).Value, duration : other.Duration, isMaster : isMaster.Substitute(value : other.IsMaster)) { }