Summary
Composes self Specification
with LengthSpecification<T>
negation for candidate property:
Checks if length of candidate property is not equal to specific value.
Syntax
[PublicAPI]
[NotNull]
public static IComplexSpecification<T> NotLength<T, TProperty>(this ICompositeSpecification<T> self, Expression<Func<T, TProperty>> selector, int length)
where TProperty : IEnumerable
Attributes
Type |
Description |
PublicAPI |
|
NotNull |
|
Type Parameters
Name |
Description |
T |
Type of candidate property to verify (collection or string). |
TProperty |
Type of candidate property to verify (collection or string). |
Parameters
Name |
Type |
Description |
self |
ICompositeSpecification<T> |
Self specification. |
selector |
Expression<Func<T, TProperty>> |
Candidate property selector. |
length |
int |
Not expected candidate property length. |
Return Value
Exceptions
Type |
Description |
System.ArgumentNullException |
Thrown when self or selector is null. |
System.ArgumentException |
Thrown when selector is not valid. |