Doxygen XLinks
by
V: 2511R0
Website: doxygen
Loading...
Searching...
No Matches
dxl::Target::TemplateArguments Struct Reference

Description:

A List of template arguments. This is not a vector or list container, but a mono-allocated array of arguments. Construction and allocation is done with the static method PARSE.

The names of the arguments are not given by doxygen, and, as far as we see, doxygen attaches those only to specializations of template types. (Not to the original type and not to templated functions.)

A few standardizations in respect to spacing are performed. This enables to easily identify whether a given XLink and a corresponding Target share the exact same parameters.

Definition at line 139 of file target.hpp.

#include <target.hpp>

Public Static Method Index:

static TemplateArgumentsPARSE (alib::MonoAllocator &ma, alib::Substring &parser)

Public Field Index:

alib::StringArguments
 An array of length Count of strings.
int Count
 The number of arguments.

Public Method Index:

 TemplateArguments ()
 Constructor.
int Match (TemplateArguments &target)
void Print (alib::AString &dest)

Field Details:

◆ Arguments

alib::String* dxl::Target::TemplateArguments::Arguments

An array of length Count of strings.

Definition at line 144 of file target.hpp.

◆ Count

int dxl::Target::TemplateArguments::Count

The number of arguments.

Definition at line 141 of file target.hpp.

Constructor(s) / Destructor Details:

◆ TemplateArguments()

dxl::Target::TemplateArguments::TemplateArguments ( )
inline

Constructor.

Definition at line 147 of file target.hpp.

Method Details:

◆ Match()

int dxl::Target::TemplateArguments::Match ( Target::TemplateArguments & target)

Tests if these template arguments found in an XLink match the ones in the given target. Not all the arguments need to match, and only substrings of the arguments need to be given. If each argument matches entirely, 2 is returned.

Parameters
targetThe template arguments in the potential target.
Returns
0 if the arguments do not match, 1 if the arguments match but are not completely given, and 2 if they are given in the exact specification.

Definition at line 241 of file target.cpp.

◆ PARSE()

Target::TemplateArguments * dxl::Target::TemplateArguments::PARSE ( alib::MonoAllocator & ma,
alib::Substring & parser )
static

Static method to parse an instance of this type from the given src and allocate the instance and its argument list in the given ma

Parameters
maThe mono allocator to use.
parserThe substring used for parsing. The round brackets and their contents are removed when the method returns.
Returns
The instance created and parsed. If a syntax error occurs, nullptr is returned.

Definition at line 155 of file target.cpp.

◆ Print()

void dxl::Target::TemplateArguments::Print ( alib::AString & dest)

Prints the parsed argument types in a standardized format.

Parameters
destThe destination string. The string is not cleared.

Definition at line 264 of file target.cpp.


The documentation for this struct was generated from the following files: