// Copyright © WireMock.Net using System; using System.Collections.Generic; using System.Text; using System.Threading.Tasks; using WireMock.Models; using WireMock.Types; // ReSharper disable once CheckNamespace namespace WireMock.Util; /// /// IBodyData /// public interface IBodyData { /// /// The body (as byte array). /// byte[]? BodyAsBytes { get; set; } /// /// Gets or sets the body as a file. /// string? BodyAsFile { get; set; } /// /// Is the body as file cached? /// bool? BodyAsFileIsCached { get; set; } /// /// The body (as JSON object). /// Also used for ProtoBuf. /// object? BodyAsJson { get; set; } /// /// Gets or sets a value indicating whether the Json Body String needs to be indented. /// bool? BodyAsJsonIndented { get; set; } /// /// The body as string, this is defined when BodyAsString or BodyAsJson are not null. /// string? BodyAsString { get; set; } /// /// The body as Form UrlEncoded dictionary. /// IDictionary? BodyAsFormUrlEncoded { get; set; } /// /// The detected body type (detection based on body content). /// BodyType? DetectedBodyType { get; set; } /// /// The detected body type (detection based on Content-Type). /// BodyType? DetectedBodyTypeFromContentType { get; set; } /// /// The detected compression. /// string? DetectedCompression { get; set; } /// /// The body encoding. /// Encoding? Encoding { get; set; } /// /// Defines if this BodyData is the result of a dynamically created response-string. /// public string? IsFuncUsed { get; set; } #region ProtoBuf /// /// Gets or sets the proto definition. /// public Func? ProtoDefinition { get; set; } /// /// Gets or sets the full type of the protobuf (request/response) message object. Format is "{package-name}.{type-name}". /// public string? ProtoBufMessageType { get; set; } #endregion /// /// Defines the queue to use for Server-Sent Events (string). /// public IBlockingQueue? SseStringQueue { get; set; } /// /// Defines if the body is using Server-Sent Events (string). /// public Task? BodyAsSseStringTask { get; set; } }