Udostępnij za pośrednictwem


EventPosition Struct

Definition

The position of events in an Event Hub partition, typically used in the creation of an EventHubConsumerClient.

public struct EventPosition : IEquatable<Azure.Messaging.EventHubs.Consumer.EventPosition>
type EventPosition = struct
Public Structure EventPosition
Implements IEquatable(Of EventPosition)
Inheritance
EventPosition
Implements

Properties

Earliest

Corresponds to the location of the first event present in the partition. Use this position to begin receiving from the first event that was enqueued in the partition which has not expired due to the retention policy.

Latest

Corresponds to the end of the partition, where no more events are currently enqueued. Use this position to begin receiving from the next event to be enqueued in the partition after an event consumer begins reading with this position.

Methods

Equals(EventPosition)

Determines whether the specified EventPosition is equal to this instance.

FromEnqueuedTime(DateTimeOffset)

Corresponds to a specific date and time within the partition to begin seeking an event; the event enqueued on or after the specified enqueuedTime will be read.

FromOffset(Int64, Boolean)

Corresponds to a specific offset in the partition event stream. By default, if an event is located at that offset, it will be read. Setting isInclusive to false will skip the event at that offset and begin reading at the next available event.

FromOffset(String, Boolean)

Corresponds to a specific offset in the partition event stream. By default, if an event is located at that offset, it will be read. Setting isInclusive to false will skip the event at that offset and begin reading at the next available event.

FromSequenceNumber(Int64, Boolean)

Corresponds to an event with the specified sequence number in the partition. By default, the event with this sequenceNumber will be read. Setting isInclusive to false will skip the event with that sequence number and begin reading at the next available event.

ToString()

Converts the instance to string representation.

Operators

Equality(EventPosition, EventPosition)

Determines whether the specified EventPosition instances are equal to each other.

Inequality(EventPosition, EventPosition)

Determines whether the specified EventPosition instances are not equal to each other.

Applies to