Table of Contents

Class SchemaDescriptionAttribute

Namespace
Excalibur.Dispatch.Transport.Kafka
Assembly
Excalibur.Dispatch.Transport.Kafka.dll

Specifies a description for a property in the generated JSON Schema.

[AttributeUsage(AttributeTargets.Property|AttributeTargets.Field, AllowMultiple = false, Inherited = true)]
public sealed class SchemaDescriptionAttribute : Attribute
Inheritance
SchemaDescriptionAttribute
Inherited Members
Extension Methods

Examples

public class OrderCreated
{
    [SchemaDescription("The unique identifier for this order")]
    public string OrderId { get; init; }
}

Remarks

When applied to a property, this attribute adds a description field to the property's schema definition.

This attribute is only processed when IncludeAnnotations is set to true.

Constructors

SchemaDescriptionAttribute(string)

Initializes a new instance of the SchemaDescriptionAttribute class.

public SchemaDescriptionAttribute(string description)

Parameters

description string

The description text for the JSON Schema.

Properties

Description

Gets the description text for the JSON Schema.

public string Description { get; }

Property Value

string