LibJuno 0.42.0
LibJuno is a lightweight C99 library designed specifically for embedded systems.
Loading...
Searching...
No Matches
buff_api.hpp
Go to the documentation of this file.
1/*
2 MIT License
3
4 Copyright (c) 2025 Robin A. Onsay
5
6 Permission is hereby granted, free of charge, to any person obtaining
7 a copy of this software and associated documentation files
8 (the "Software"), to deal in the Software without restriction,
9 including without limitation the rights to use, copy, modify, merge,
10 publish, distribute, sublicense, and/or sell copies of the Software,
11 and to permit persons to whom the Software is furnished to do so,
12 subject to the following conditions:
13
14 The above copyright notice and this permission notice shall be
15 included in all copies or substantial portions of the Software.
16*/
17
27#ifndef JUNO_BUFF_QUEUE_API_HPP
28#define JUNO_BUFF_QUEUE_API_HPP
29#include "juno/status.h"
30#include "juno/module.h"
31#include "juno/module.hpp"
32#include "juno/types.hpp"
33#include <cstddef>
34
35namespace juno
36{
37namespace buff
38{
39
43template<typename T, const size_t N>
44struct QUEUE_API_T;
45
49template<typename T, const size_t N>
50union QUEUE_T;
51
55template<typename T, const size_t N>
57 ARRAY_T<T,N> tArrBuff;
58 size_t iStartIndex;
59 size_t zLength;
60);
61
65template<typename T, const size_t N>
75
76
78template<typename T, const size_t N>
79struct STACK_API_T;
80
82template<typename T, const size_t N>
83union STACK_T;
84
86template<typename T, const size_t N>
89 size_t zLength;
90);
91
93template<typename T, const size_t N>
103
104}
105}
106
107#endif // JUNO_BUFF_QUEUE_API_H
#define JUNO_MODULE_ARG(...)
Definition module.h:132
#define JUNO_MODULE_ROOT(API_T,...)
Definition module.h:182
Definition buff_api.hpp:36
int32_t JUNO_STATUS_T
Definition status.h:23
Definition types.hpp:31
Definition module.hpp:29
Definition buff_api.hpp:67
RESULT_T< T * >(* Peek)(QUEUE_T< T, N > &tQueue)
Peek at the next data item in the queue buffer. Calling Dequeue would dequeue this.
Definition buff_api.hpp:73
JUNO_STATUS_T(* Enqueue)(QUEUE_T< T, N > &tQueue, T tData)
Enqueue data into the queue buffer.
Definition buff_api.hpp:69
RESULT_T< T >(* Dequeue)(QUEUE_T< T, N > &tQueue)
Dequeue data from the queue buffer.
Definition buff_api.hpp:71
The stack buffer api.
Definition buff_api.hpp:95
RESULT_T< T >(* Pop)(STACK_T< T, N > &tStack)
Pop data from the stack buffer.
Definition buff_api.hpp:99
RESULT_T< T * >(* Peek)(STACK_T< T, N > &tStack)
Peek into data on the stack buffer.
Definition buff_api.hpp:101
JUNO_STATUS_T(* Push)(STACK_T< T, N > &tStack, T tData)
Push data onto the stack buffer.
Definition buff_api.hpp:97
Definition buff_api.hpp:50
The stack module.
Definition buff_api.hpp:83