/// <summary>
        /// Initializes a new instance of the <see cref="CheckRecordExistsOp"/> class.
        /// </summary>
        /// <param name="streamRepresentation">The <see cref="IStreamRepresentation"/> to resolve the <see cref="IStream"/> to check handling on.</param>
        /// <param name="recordFilter">The filter for the records to examine.</param>
        public CheckRecordExistsOp(
            IStreamRepresentation streamRepresentation,
            RecordFilter recordFilter)
        {
            streamRepresentation.MustForArg(nameof(streamRepresentation)).NotBeNull();
            recordFilter.MustForArg(nameof(recordFilter)).NotBeNull();

            this.StreamRepresentation = streamRepresentation;
            this.RecordFilter         = recordFilter;
        }
Example #2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="CheckRecordHandlingOp"/> class.
        /// </summary>
        /// <param name="streamRepresentation">The <see cref="IStreamRepresentation"/> to resolve the <see cref="IStream"/> to check handling on.</param>
        /// <param name="concern">The concerns that require handling.</param>
        /// <param name="recordFilter">The filter for the records to examine.</param>
        /// <param name="handlingFilter">The filter for the handling entries to examine.</param>
        public CheckRecordHandlingOp(
            IStreamRepresentation streamRepresentation,
            string concern,
            RecordFilter recordFilter,
            HandlingFilter handlingFilter)
        {
            streamRepresentation.MustForArg(nameof(streamRepresentation)).NotBeNull();
            concern.MustForArg(nameof(concern)).NotBeNullNorWhiteSpace();
            recordFilter.MustForArg(nameof(recordFilter)).NotBeNull();
            handlingFilter.MustForArg(nameof(handlingFilter)).NotBeNull();

            this.StreamRepresentation = streamRepresentation;
            this.Concern        = concern;
            this.RecordFilter   = recordFilter;
            this.HandlingFilter = handlingFilter;
        }
        /// <summary>
        /// Initializes a new instance of the <see cref="RecordFilterEntry"/> class.
        /// </summary>
        /// <param name="id">The identifier of the entry.</param>
        /// <param name="streamRepresentation">The stream representation.</param>
        /// <param name="recordFilter">The record filter.</param>
        /// <param name="requiredForReaction">if set to <c>true</c> [required for reaction].</param>
        /// <param name="includeInReaction">if set to <c>true</c> [include in reaction].</param>
        public RecordFilterEntry(
            string id,
            IStreamRepresentation streamRepresentation,
            RecordFilter recordFilter,
            bool requiredForReaction,
            bool includeInReaction)
        {
            id.MustForArg(nameof(id)).NotBeNullNorWhiteSpace();
            streamRepresentation.MustForArg(nameof(streamRepresentation)).NotBeNull();
            recordFilter.MustForArg(nameof(recordFilter)).NotBeNull();

            this.Id = id;
            this.StreamRepresentation = streamRepresentation;
            this.RecordFilter         = recordFilter;
            this.RequiredForReaction  = requiredForReaction;
            this.IncludeInReaction    = includeInReaction;
        }