Delen via


EventGridEvent Constructors

Definition

Overloads

EventGridEvent(String, String, String, BinaryData)

Initializes a new instance of EventGridEvent.

EventGridEvent(String, String, String, Object, Type)

Initializes a new instance of EventGridEvent.

EventGridEvent(String, String, String, BinaryData)

Source:
EventGridEvent.cs
Source:
EventGridEvent.cs

Initializes a new instance of EventGridEvent.

public EventGridEvent (string subject, string eventType, string dataVersion, BinaryData data);
new Azure.Messaging.EventGrid.EventGridEvent : string * string * string * BinaryData -> Azure.Messaging.EventGrid.EventGridEvent
Public Sub New (subject As String, eventType As String, dataVersion As String, data As BinaryData)

Parameters

subject
String

A resource path relative to the topic path.

eventType
String

The type of the event that occurred. For example, "Contoso.Items.ItemReceived".

dataVersion
String

The schema version of the data object.

data
BinaryData

Pre-serialized JSON event data specific to the event type.

Exceptions

subject, data, eventType, or dataVersion was null.

Applies to

EventGridEvent(String, String, String, Object, Type)

Source:
EventGridEvent.cs
Source:
EventGridEvent.cs

Initializes a new instance of EventGridEvent.

public EventGridEvent (string subject, string eventType, string dataVersion, object data, Type dataSerializationType = default);
new Azure.Messaging.EventGrid.EventGridEvent : string * string * string * obj * Type -> Azure.Messaging.EventGrid.EventGridEvent
Public Sub New (subject As String, eventType As String, dataVersion As String, data As Object, Optional dataSerializationType As Type = Nothing)

Parameters

subject
String

A resource path relative to the topic path.

eventType
String

The type of the event that occurred. For example, "Contoso.Items.ItemReceived".

dataVersion
String

The schema version of the data object.

data
Object

Event data specific to the event type.

dataSerializationType
Type

The type to use when serializing the data. If not specified, GetType() will be used on data.

Exceptions

subject, data, eventType, or dataVersion was null.

Applies to