|
Open Model Railroad Network (OpenMRN)
|
Terminates the class recursion template. More...
#include <OptionalArgs.hxx>
Public Member Functions | |
| template<typename... Args> | |
| constexpr | OptionalArg (Args... args) |
| Constructor. | |
| template<class FF > | |
| constexpr FF | get (const FF f) const |
| End of template recursion. | |
| template<class FF > | |
| constexpr bool | has (const FF f) const |
| End of template recursion. | |
Static Private Member Functions | |
| static constexpr int | check_arguments_are_valid (const OptionalArg &a) |
| End of recursion with no leftover arguments. | |
| template<typename A , typename... Args> | |
| static constexpr int | check_all_args (const A a, Args... args) |
| Beginning of recursion.. | |
| static constexpr int | check_all_args () |
| End of recursion. | |
| static bool | tried_to_get_unknown_argument () |
| unimplemented, causes a link error. Do not ever implement it. | |
Private Attributes | |
| const int | check_ |
| This is here only to force computing the check_all_args at compile time (constexpr!). | |
Terminates the class recursion template.
The constructor is used to check that the customer has specified only known parameters.
The get function throws an error deterministically, because if the compiler gets this deep in the get function, then none of the actual data carrying components matched on the type. This means that the customer is trying to fetch something we didn't store.
Definition at line 122 of file OptionalArgs.hxx.
|
inlineconstexpr |
|
inlinestaticconstexprprivate |
End of recursion.
Definition at line 162 of file OptionalArgs.hxx.
|
inlinestaticconstexprprivate |
Beginning of recursion..
Definition at line 156 of file OptionalArgs.hxx.
|
inlinestaticconstexprprivate |
End of recursion with no leftover arguments.
Definition at line 149 of file OptionalArgs.hxx.
|
inlineconstexpr |
End of template recursion.
Fails to link.
| f | unknown argument specification. |
Definition at line 134 of file OptionalArgs.hxx.
|
inlineconstexpr |
End of template recursion.
Fails to link.
| f | unknown argument specification. |
Definition at line 141 of file OptionalArgs.hxx.
|
private |
This is here only to force computing the check_all_args at compile time (constexpr!).
Definition at line 172 of file OptionalArgs.hxx.