-
Notifications
You must be signed in to change notification settings - Fork 2
valueList
Igor Zarzycki edited this page Jan 23, 2022
·
11 revisions
Defined in "crap/utility.d/valuelist.h".
Defined in "crap/utility".
template <class Type, Type ... Values> struct valueList;
Basic structure storing and operating on Values...
of type Type
.
-
Type
- type of values being stored. -
Values...
- values being stored.
-
size
- number of values being stored (for details see valueList :: size). -
at
- value stored at passed position (for details see valueList :: at). Avaliable since C++14 language version.
-
At
- give random access to elements stored in collection (for details see valueList :: At). -
Till
- creates subcollection of elements since begining till passed point (for details see valueList :: Till). -
Since
- creates subset of collection since passed point till end (for details see valueList :: Since). -
copy
- copies whole collection to passed container (for details see valueList :: copy). -
till
- copies subset of collection since begining till passed point into passed container (for details see valueList :: till). -
since
- copies subset of collection since passed point into passed container (for details see valueList :: since).
#include <crap/utility.d/printer.h>
#include <crap/utility.d/valuelist.h>
#include <iostream>
int main()
{
using test = crap :: valueList<unsigned int, 0u, 1u, 2u, 3u, 4u, 5u, 6u, 7u>;
crap :: printer :: print(std :: cout, ", ", test{});
}
0, 1, 2, 3, 4, 5, 6, 7,