Found 11 packages
.NotEmpty<T>() test extension
Simple helper methods for verifying argument values.
A JavaScript library with function argument assertions, a function parser and assertion wrapper functionality. By wrapping your functions you get defined, notNull, bool, func, number, object, string and notEmpty assertions for free. The interface is specially optimised for the Visual Studio JavaScript IntelliSense. Note that the assertions are not for unit testing, but for function arguments. This is a JavaScript design by contract (DbC) implementation. For more information about DcB visit: http://en.wikipedia.org/wiki/Design_by_contract.
Common implementation of small reusable Specifications. All Specifications are based on Specification design pattern. Specifications support validation scenarios and also can be used like Linq expressions, because they are designed and implemented especially for Entity Framework Core support and partially for Entity Framework 6 and tested with these frameworks. Contains Specifications: - Null, NotNull - Empty, NotEmpty - MinLength, MaxLength - LessThan, GreaterThan - Contains, NotContains - Equals, NotEquals - And more...
contains XFormatProvider that extends standard string format modifiers with custom formatters e.g. ColorFormatter, NotEmptyFormatter, PriceFormatter, EnumFormatter etc.
O2YO.FluentValidation Developed by: Shafi Hussain Description: The O2YO.FluentValidation package provides a powerful and flexible way to perform fluent validation on objects in C#. With this package, you can easily define validation rules for your models using fluent syntax, making your validation logic clean, concise, and easy to understand. Features and Functionalities: Async Support: All validation methods support asynchronous operations, allowing you to validate your models asynchronously for improved performance and responsiveness. Validation Rules: NotEmptyAsync: Validates that a property is not null or empty. NotNullAsync: Validates that a property is not null. NotEqualToAsync: Validates that a property is not equal to a specified value. EqualToAsync: Validates that a property is equal to a specified value. LengthInRangeAsync: Validates that the length of a string property or the count of a collection property falls within a specified range. MaxLengthAsync: Validates that the length of a string property or the count of a collection property does not exceed a specified maximum. MinLengthAsync: Validates that the length of a string property or the count of a collection property meets or exceeds a specified minimum. LessThanAsync: Validates that a numeric property is less than a specified threshold. LessThanOrEqualToAsync: Validates that a numeric property is less than or equal to a specified threshold. GreaterThanAsync: Validates that a numeric property is greater than a specified threshold. GreaterThanOrEqualToAsync: Validates that a numeric property is greater than or equal to a specified threshold. CreditCardAsync: Validates that a string property represents a valid credit card number. MobileNumberAsync: Validates that a string property represents a valid 10-digit mobile number. SpecialCharacterAsync: Validates that a string property does not contain any special characters. SpaceOnlyAsync: Validates that a string property contains only spaces. NoSpaceAsync: Validates that a string property does not contain any spaces. IsAlphabateAsync: Validates that a string property contains only alphabetic characters and spaces. EmailAsync: Validates that a string property represents a valid email address. USAGE: // Example usage of validation rules var validator = new O2YOValidate<UserModel>(user, new List<string>()); await validator.NotEmptyAsync(x => x.Name); await validator.EmailAsync(x => x.Email); // Add more validation rules as needed Compatibility: This package is compatible with .NET Standard and .NET Core, ensuring seamless integration into your existing projects. Contributions: Contributions to this package are welcome! If you encounter any issues or have suggestions for improvements, please feel free to contribute to the GitHub repository. License: This package is distributed under the MIT License, allowing for both personal and commercial use with minimal restrictions. With O2YO.FluentValidation, validating your C# models has never been easier. Ensure the integrity and consistency of your data with confidence. Get started with O2YO.FluentValidation today!
Validated value objects for domain modeling - NotEmptyString, RequiredGuid, and more