This commit is contained in:
CortexCore
2023-10-02 23:24:56 +08:00
parent 8ef5c7ec0a
commit 947e52e748
183 changed files with 107857 additions and 9378 deletions

View File

@@ -3,7 +3,10 @@ using System.Collections.Generic;
namespace BITKit
{
/// <summary>
/// 双缓冲区
/// </summary>
/// <typeparam name="T"></typeparam>
public interface IDoubleBuffer<T>
{
T Current { get; }
@@ -11,7 +14,10 @@ namespace BITKit
event Action<T> OnRelease;
bool TryGetRelease(out T result);
}
/// <summary>
/// <see cref="IDoubleBuffer{T}"/>
/// </summary>
/// <typeparam name="T"></typeparam>
public class DoubleBuffer<T> : IDoubleBuffer<T>
{
public T Current