Maria GDK 5.0.0.738
Documentation of native code in develop branch
Loading...
Searching...
No Matches
Maria::MAlphaLabelsGenerator Class Reference

Gets an array of lenght 'numberOfLabels' of lexicographically consecutive(*) capital letter strings of arbitrary lenght. (*) Successor of AA = AB, successor of NILZ = NIMA, successor of ZZZ = AAAA. More...

#include <MAlphaGenerator.h>

Public Member Functions

 MAlphaLabelsGenerator ()
 Default constructor, start = A, all letters allowed and no unwanted strings.
 
 MAlphaLabelsGenerator (const std::string &start, const std::string &exempted_chars, const std::set< std::string > exempted_strings)
 Constructor.
 
std::string Next (const std::string &current)
 Gets next string in the sequence, without check for exemption.
 
std::vector< std::string > GetAlphaLabels (int n)
 Gets an array of n strings, not containing exempted strings.
 

Detailed Description

Gets an array of lenght 'numberOfLabels' of lexicographically consecutive(*) capital letter strings of arbitrary lenght. (*) Successor of AA = AB, successor of NILZ = NIMA, successor of ZZZ = AAAA.

The source alphabet [A,...,Z] may be initially purged by removing unwanted letters. If B is unwanted, successor of AA is AC Unwanted strings will not appear in the returned array. If NIMA is unwanted, successor of NILZ is NIMB

Constructor & Destructor Documentation

◆ MAlphaLabelsGenerator()

Maria::MAlphaLabelsGenerator::MAlphaLabelsGenerator ( const std::string &  start,
const std::string &  exempted_chars,
const std::set< std::string >  exempted_strings 
)
inline

Constructor.

Parameters
startStart string of arbitrary length, all consecutive strings will be of the same length or longer
exempted_charsA string containing unwnted letters
exempted_stringsUnwanted strings

Member Function Documentation

◆ GetAlphaLabels()

std::vector< std::string > Maria::MAlphaLabelsGenerator::GetAlphaLabels ( int  n)
inline

Gets an array of n strings, not containing exempted strings.

Parameters
n
Returns

◆ Next()

std::string Maria::MAlphaLabelsGenerator::Next ( const std::string &  current)
inline

Gets next string in the sequence, without check for exemption.

Parameters
currentCurrent string
Returns

The documentation for this class was generated from the following file: