Code Cleanup: SyncSet

Consistent order of things
This commit is contained in:
MrGadget 2024-10-15 06:02:50 -04:00
parent c23914ca2b
commit 86302503da

View File

@ -15,6 +15,13 @@ public class SyncSet<T> : SyncObject, ISet<T>
/// <summary>This is called BEFORE the data is cleared</summary> /// <summary>This is called BEFORE the data is cleared</summary>
public Action OnClear; public Action OnClear;
public enum Operation : byte
{
OP_ADD,
OP_REMOVE,
OP_CLEAR
}
/// <summary> /// <summary>
/// This is called for all changes to the Set. /// This is called for all changes to the Set.
/// <para>For OP_ADD, T is the NEW value of the entry.</para> /// <para>For OP_ADD, T is the NEW value of the entry.</para>
@ -28,13 +35,6 @@ public class SyncSet<T> : SyncObject, ISet<T>
public int Count => objects.Count; public int Count => objects.Count;
public bool IsReadOnly => !IsWritable(); public bool IsReadOnly => !IsWritable();
public enum Operation : byte
{
OP_ADD,
OP_REMOVE,
OP_CLEAR
}
struct Change struct Change
{ {
internal Operation operation; internal Operation operation;