Table of Contents

Class GenerateMessageExpirationAttribute

Namespace
PatternKit.Generators.Messaging
Assembly
PatternKit.Generators.Abstractions.dll

Generates a typed message-expiration policy factory for a partial class or struct.

[AttributeUsage(AttributeTargets.Class|AttributeTargets.Struct, AllowMultiple = false, Inherited = false)]
public sealed class GenerateMessageExpirationAttribute : Attribute
Inheritance
GenerateMessageExpirationAttribute
Inherited Members

Constructors

GenerateMessageExpirationAttribute(Type)

Creates a message-expiration generator attribute.

public GenerateMessageExpirationAttribute(Type payloadType)

Parameters

payloadType Type

Properties

DefaultTtlMilliseconds

Default TTL, in milliseconds, used by Stamp. Values less than or equal to zero omit the default TTL.

public int DefaultTtlMilliseconds { get; set; }

Property Value

int

ExpiredReason

Reason returned when a message is expired.

public string ExpiredReason { get; set; }

Property Value

string

FactoryName

Name of the generated factory method.

public string FactoryName { get; set; }

Property Value

string

HeaderName

Header used to store expiration deadlines.

public string HeaderName { get; set; }

Property Value

string

PayloadType

Payload type stamped and evaluated by the generated expiration policy.

public Type PayloadType { get; }

Property Value

Type

PolicyName

Name assigned to the generated expiration policy.

public string PolicyName { get; set; }

Property Value

string

PreserveExisting

Whether stamping keeps an existing expiration deadline.

public bool PreserveExisting { get; set; }

Property Value

bool