Reference documentation for deal.II version 9.0.0
|
#include <deal.II/base/patterns.h>
Store information about the rank types of the given class.
A class has Rank equal to the number of different separators that are required to uniquely identify its element(s) in a string.
This class is used to detect whether the class T is compatible with a Patterns::List pattern or with a Patterns::Map pattern.
Objects like Point() or std::complex<double> are vector-likes, and have vector_rank 1. Elementary types, like int
, unsigned int
, double
, etc. have vector_rank 0. std::vector
, std::list
and in general containers have rank equal to 1 + vector_rank of the contained type. Similarly for map types.
A class with list_rank::value = 0 is either elementary or a map. A class with map_rank::value = 0 is either a List compatible class, or an elementary type.
Elementary types are not compatible with Patterns::List, but non elementary types, like Point(), or std::complex<double>, are compatible with the List type. Adding more compatible types is a matter of adding a specialization of this struct for the given type.
Definition at line 1411 of file patterns.h.