Beispiel #1
0
 /// <inheritdoc />
 public NotSpecification(ISpecificationAlgebra <T> algebra, ISpecification <T> argument)
     : base(
         algebra.GetHighestPrioritizedAlgebra <Specification <T>, ISpecificationAlgebra <T> >((argument as IDefineAlgebraicDomain <Specification <T>, ISpecificationAlgebra <T> >)?.Algebra),
         null)
 {
     _argument = argument;
 }
Beispiel #2
0
 /// <summary>Initializes a new instance of the <see cref="CompositeSpecification{T}"/> class.</summary>
 /// <param name="algebra">The algebra.</param>
 /// <param name="operation">The operator.</param>
 /// <param name="arguments">The arguments.</param>
 public CompositeSpecification(ISpecificationAlgebra <T> algebra,
                               CompositeSpecificationOperation operation,
                               params ISpecification <T>[] arguments
                               )
     : base(algebra.GetHighestPrioritizedAlgebra <Specification <T>, ISpecificationAlgebra <T> >(arguments.OfType <IDefineAlgebraicDomain <Specification <T>, ISpecificationAlgebra <T> > >().Select(a => a.Algebra)), null)
 {
     Operation  = operation;
     _arguments = GetFlatArgumentsArray(operation, arguments);
 }
 /// <inheritdoc />
 public PredicateSpecification(ISpecificationAlgebra <T> algebra, Func <T, bool> predicate, SpecificationDescriptor descriptor = null)
     : base(algebra, descriptor)
 {
     _predicate = predicate;
 }
 /// <inheritdoc />
 public TrueSpecification(ISpecificationAlgebra <T> algebra, SpecificationDescriptor descriptor = null) : base(algebra, descriptor)
 {
 }
Beispiel #5
0
 public WrappedSpecification(ISpecificationAlgebra <T> algebra, ISpecification <TWrapped> wrapped) : base(algebra, wrapped.Descriptor)
 {
     _wrapped = wrapped;
 }
 public CandidateConverterSpecification(ISpecificationAlgebra <TDestination> algebra, ISpecification <TSource> original, Func <TDestination, TSource> convertCandidateCallback) : base(algebra, original.Descriptor)
 {
     _original = original;
     _convertCandidateCallback = convertCandidateCallback;
 }