mirror of https://github.com/Squidex/squidex.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
34 lines
1.1 KiB
34 lines
1.1 KiB
// ==========================================================================
|
|
// Squidex Headless CMS
|
|
// ==========================================================================
|
|
// Copyright (c) Squidex UG (haftungsbeschränkt)
|
|
// All rights reserved. Licensed under the MIT license.
|
|
// ==========================================================================
|
|
|
|
namespace Squidex.Infrastructure.EventSourcing
|
|
{
|
|
public sealed class StoredEvent
|
|
{
|
|
public string StreamName { get; }
|
|
|
|
public string EventPosition { get; }
|
|
|
|
public long EventStreamNumber { get; }
|
|
|
|
public EventData Data { get; }
|
|
|
|
public StoredEvent(string streamName, string eventPosition, long eventStreamNumber, EventData data)
|
|
{
|
|
Guard.NotNullOrEmpty(streamName, nameof(streamName));
|
|
Guard.NotNullOrEmpty(eventPosition, nameof(eventPosition));
|
|
Guard.NotNull(data, nameof(data));
|
|
|
|
Data = data;
|
|
|
|
EventPosition = eventPosition;
|
|
EventStreamNumber = eventStreamNumber;
|
|
|
|
StreamName = streamName;
|
|
}
|
|
}
|
|
}
|
|
|