#ifndef FRAMEWORK_CONTAINER_FIFO_H_ #define FRAMEWORK_CONTAINER_FIFO_H_ #include "FIFOBase.h" #include /** * @brief Simple First-In-First-Out data structure with size fixed at * compile time * @details * Performs no dynamic memory allocation. * The public interface of FIFOBase exposes the user interface for the FIFO. * @tparam T Entry Type * @tparam capacity Maximum capacity */ template class FIFO: public FIFOBase { public: FIFO(): FIFOBase(fifoArray.data(), capacity) {}; /** * @brief Custom copy constructor to set pointer correctly. * @param other */ FIFO(const FIFO& other): FIFOBase(other) { this->setData(fifoArray.data()); } private: std::array fifoArray; }; #endif /* FRAMEWORK_CONTAINERS_STATICFIFO_H_ */