Files
WireMock.Net/src/WireMock.Net.Abstractions/Admin/Mappings/MappingModel.cs
Stef Heyenrath 6ac95cf57d Add Grpc ProtoBuf support (request-response) (#1047)
* ProtoBuf

* .

* x

* ---

* x

* fx

* ...

* sc

* ...

* .

* groen

* x

* fix tests

* ok!?

* fix tests

* fix tests

* !

* x

* 6

* .

* x

* ivaluematcher

* transformer

* .

* sc

* .

* mapping

* x

* tra

* com

* ...

* .

* .

* .

* AddProtoDefinition

* .

* set

* grpahj

* .

* .

* IdOrText

* ...

* async

* async2

* .

* t

* nuget

* <PackageReference Include="ProtoBufJsonConverter" Version="0.2.0-preview-04" />

* http version

* tests

* .WithHttpVersion("2")

* <PackageReference Include="ProtoBufJsonConverter" Version="0.2.0" />

* HttpVersionParser
2024-02-16 17:16:51 +01:00

106 lines
2.7 KiB
C#

using System;
using WireMock.Models;
namespace WireMock.Admin.Mappings;
/// <summary>
/// MappingModel
/// </summary>
[FluentBuilder.AutoGenerateBuilder]
public class MappingModel
{
/// <summary>
/// Gets or sets the unique identifier.
/// </summary>
public Guid? Guid { get; set; }
/// <summary>
/// The datetime when this mapping was created or updated.
/// </summary>
public DateTime? UpdatedAt { get; set; }
/// <summary>
/// Gets or sets the TimeSettings when which this mapping should be used.
/// </summary>
public TimeSettingsModel? TimeSettings { get; set; }
/// <summary>
/// The unique title.
/// </summary>
public string? Title { get; set; }
/// <summary>
/// The description.
/// </summary>
public string? Description { get; set; }
/// <summary>
/// The priority. (A low value means higher priority.)
/// </summary>
public int? Priority { get; set; }
/// <summary>
/// The Scenario.
/// </summary>
public string? Scenario { get; set; }
/// <summary>
/// Execution state condition for the current mapping.
/// </summary>
public string? WhenStateIs { get; set; }
/// <summary>
/// The next state which will be signaled after the current mapping execution.
/// In case the value is null state will not be changed.
/// </summary>
public string? SetStateTo { get; set; }
/// <summary>
/// The request model.
/// </summary>
public RequestModel Request { get; set; }
/// <summary>
/// The response model.
/// </summary>
public ResponseModel Response { get; set; }
/// <summary>
/// Saves this mapping as a static mapping file.
/// </summary>
public bool? SaveToFile { get; set; }
/// <summary>
/// The Webhook.
/// </summary>
public WebhookModel? Webhook { get; set; }
/// <summary>
/// The Webhooks.
/// </summary>
public WebhookModel[]? Webhooks { get; set; }
/// <summary>
/// Fire and forget for webhooks.
/// </summary>
public bool? UseWebhooksFireAndForget { get; set; }
/// <summary>
/// Data Object which can be used when WithTransformer is used.
/// e.g. lookup an path in this object using
/// <example>
/// lookup data "1"
/// </example>
/// </summary>
public object? Data { get; set; }
/// <summary>
/// The probability when this request should be matched. Value is between 0 and 1. [Optional]
/// </summary>
public double? Probability { get; set; }
/// <summary>
/// The Grpc ProtoDefinition which is used for this mapping (request and response). [Optional]
/// </summary>
public string? ProtoDefinition { get; set; }
}