ADS
Algorithms and Data Structures
Toggle main menu visibility
Loading...
Searching...
No Matches
QueueAlgorithms.h
Go to the documentation of this file.
1
/*--------------------------------------------------------------------------*/
2
/*------------------------- File QueueAlgorithms.h -------------------------*/
3
/*--------------------------------------------------------------------------*/
27
/*--------------------------------------------------------------------------*/
28
/*----------------------------- DEFINITIONS --------------------------------*/
29
/*--------------------------------------------------------------------------*/
30
31
#ifndef __ADS_QueueAlgorithms
32
#define __ADS_QueueAlgorithms
33
/* self-identification: #endif constant */
34
35
/*--------------------------------------------------------------------------*/
36
/*------------------------------ INCLUDES ----------------------------------*/
37
/*--------------------------------------------------------------------------*/
38
39
#include "
ADS/ADT.h
"
40
#include "
ADS/Contract.h
"
41
#include "
ADS/queue/LinkedQueue.h
"
42
43
#include <vector>
44
45
/*--------------------------------------------------------------------------*/
46
/*--------------------------- NAMESPACE ------------------------------------*/
47
/*--------------------------------------------------------------------------*/
48
49
namespace
ADS
50
{
51
67
template
< Queue Q >
68
void
extractPositive
( Q & q , Q & out );
69
91
template
< Queue Q >
92
void
copyPositive
( Q & q , Q & out );
93
94
/*--------------------------------------------------------------------------*/
95
96
}
// end( namespace ADS )
97
98
/*--------------------------------------------------------------------------*/
99
/*-------------------------- IMPLEMENTATION --------------------------------*/
100
/*--------------------------------------------------------------------------*/
101
102
#include "ADS/queue/impl/QueueAlgorithms.tpp"
103
104
/*--------------------------------------------------------------------------*/
105
106
#endif
/* QueueAlgorithms.h included */
107
108
/*--------------------------------------------------------------------------*/
109
/*----------------------- End File QueueAlgorithms.h -----------------------*/
110
/*--------------------------------------------------------------------------*/
ADT.h
The abstract data types of the book, as concepts of C++20: SEQUENCE, SET and DICTIONARY (chapter 3),...
Contract.h
The contracts of ADS: the preconditions, the postconditions and the invariants of the operations,...
LinkedQueue.h
A QUEUE [see ADT.h] realized as a singly linked list with a pointer to the first cell,...
ADS::extractPositive
void extractPositive(Q &q, Q &out)
moves the positive items of , in their order, to the back of out, leaving empty
ADS::copyPositive
void copyPositive(Q &q, Q &out)
copies the positive items of , in their order, to the back of out, leaving as it was
ADS
Definition
ADT.h:96
ADS
queue
QueueAlgorithms.h
Generated by
1.17.0