#region File Header
//
// IFiniteQueue.cs - Common interface for all types of finite queues
//
// Copyright (C) Javier Valcarce. BSD License
#endregion
#region Using Statements
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
#endregion
namespace SolarPanel
{
///
/// Generic Finite Queue. There are many versions of this concept,
/// thread-safe with blocking API
/// thread-safe with non-blocking API
/// non thread-safe (and therefore non-blocking API)
///
/// Generic type
interface IFiniteQueue
{
void Clear();
int Enqueue(T item);
int Enqueue(T[] src, int offset, int count);
int Dequeue(out T item);
int Dequeue(T[] dst, int offset, int count);
T this[int index] { get; set; }
int Capacity { get; }
int Count { get; }
int Space { get; }
}
}