refactor: Actions to Delegates
This commit is contained in:
@@ -1,5 +1,3 @@
|
||||
using System;
|
||||
|
||||
namespace Syntriax.Engine.Core.Abstract;
|
||||
|
||||
/// <summary>
|
||||
@@ -11,10 +9,12 @@ public interface IEntity : IInitialize, IAssignableStateEnable
|
||||
/// Event triggered when the <see cref="Id"/> of the <see cref="IEntity"/> changes.
|
||||
/// The string action parameter is the previous <see cref="Id"/> of the <see cref="IEntity"/>.
|
||||
/// </summary>
|
||||
Action<IEntity, string>? OnIdChanged { get; set; }
|
||||
event OnIdChangedDelegate? OnIdChanged;
|
||||
|
||||
/// <summary>
|
||||
/// The ID of the <see cref="IEntity"/>.
|
||||
/// </summary>
|
||||
string Id { get; set; }
|
||||
|
||||
delegate void OnIdChangedDelegate(IEntity sender, string previousId);
|
||||
}
|
||||
|
Reference in New Issue
Block a user