Files
DocumentService/DocumentOperator.Application/CheckPdfAttachments/Queries/CheckPdfAttachmentsQueryValidator.cs
TekH c93488c29f refactor(application): migrate all queries to Stream-based API
- Replace byte[] and Base64String with required Stream PdfStream
- Simplify validators: remove XOR/Base64 validation, only check NotNull
- Affected queries: ValidatePdfQuery, ValidatePdfAQuery, CheckPdfAttachmentsQuery, ExtractSwissQrCodeQuery
- Memory efficiency: direct stream usage, no intermediate byte[] copies
2026-07-20 16:31:14 +02:00

19 lines
522 B
C#

using FluentValidation;
namespace DocumentOperator.Application.CheckPdfAttachments.Queries;
/// <summary>
/// Validator for CheckPdfAttachmentsQuery
/// Ensures PdfStream is not null
/// </summary>
public class CheckPdfAttachmentsQueryValidator : AbstractValidator<CheckPdfAttachmentsQuery>
{
public CheckPdfAttachmentsQueryValidator()
{
// Rule: PdfStream must be provided and non-empty
RuleFor(x => x.PdfStream)
.NotNull()
.WithMessage("PdfStream is required");
}
}