ZenLib
Public Member Functions | Protected Attributes | List of all members
ZenLib::ZtringListList Class Reference

Vector of vectors of strings manipulation (based on std::vector<std::vector<std::(w)string>>) More...

#include <ZtringListList.h>

Inheritance diagram for ZenLib::ZtringListList:
ZenLib::ZtringListListF

Public Member Functions

 ZtringListList ()
 
 ZtringListList (const ZtringListList &Source)
 
 ZtringListList (const Ztring &Source)
 
 ZtringListList (const Char *Source)
 
bool operator== (const ZtringListList &Source) const
 
bool operator!= (const ZtringListList &Source) const
 
ZtringListListoperator+= (const ZtringListList &Source)
 
ZtringListListoperator= (const ZtringListList &Source)
 
ZtringListoperator() (size_type Pos0)
 Same as [], but write a empty string if Pos doesn't exist yet. More...
 
Ztringoperator() (size_type Pos0, size_type Pos1)
 
Ztringoperator() (const Ztring &Pos0, size_type Pos1=1)
 Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][0]. More...
 
Ztringoperator() (const Ztring &Pos0, size_type Pos0_1, size_type Pos1)
 Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][Pos0_1]. More...
 
Ztring Read () const
 Read all. More...
 
Ztring Read (size_type Pos0) const
 Read a vector of string. More...
 
const ZtringRead (size_type Pos0, size_type Pos1) const
 Read a string. More...
 
const ZtringRead (const Ztring &Pos0, size_type Pos1=1) const
 Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][0]. More...
 
const ZtringRead (const Ztring &Pos0, size_type Pos0_1, size_type Pos1) const
 Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][Pos0_1]. More...
 
const ZtringRead (const Ztring &Pos0, const Ztring &Default, size_type Pos1=1) const
 Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][0], with default value. More...
 
const ZtringRead (const Ztring &Pos0, const Ztring &Default, size_type Pos0_1, size_type Pos1) const
 Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][Pos0_1], with default value. More...
 
Ztring Read1 (size_type Pos1) const
 Read all strings at position Pos1. More...
 
void Write (const Ztring &ToWrite)
 Write all. More...
 
void Write (const ZtringList &ToWrite, size_type Pos0)
 Write a vector of string. More...
 
void Write (const Ztring &ToWrite, size_type Pos0, size_type Pos1)
 Write a vector of string. More...
 
void push_back (const ZtringList &ToAdd)
 Add a vector of string. More...
 
void push_back (const Ztring &ToAdd)
 Add a vector of string (with separator is ZtringListList Separator) More...
 
void push_back (const Char *ToAdd)
 Add a vector of string (Char version) More...
 
void Insert (const ZtringList &ToInsert, size_type Pos0)
 Insert a vector of string at position Pos0. More...
 
void Insert1 (const Ztring &ToInsert, size_type Pos1)
 Insert a string at all positions Pos1. More...
 
void Delete (size_type Pos0)
 Delete a vector of string at position Pos0. More...
 
void Delete (const Ztring &ToFind, size_type Pos1=0, const Ztring &Comparator=__T("=="), ztring_t Options=Ztring_Nothing)
 Delete all vectors of string, with [xxx][Pos1] == ToFind. More...
 
void Delete1 (size_type Pos1)
 Delete a string at all positions Pos1. More...
 
void Swap (size_type Pos0_A, size_type Pos0_B)
 Swap 2 positions. More...
 
void Swap1 (size_type Pos1_A, size_type Pos1_B)
 Swap 2 columns for each line. More...
 
void Sort (size_type Pos1, ztring_t Options=Ztring_Nothing)
 Sort. More...
 
size_type Find (const Ztring &ToFind, size_type Pos1=0, size_type Pos0Begin=0) const
 Find the first position of the string in the vector of vector, in a specific column. More...
 
size_type Find_Filled (size_type Pos1=0, size_type Pos0Begin=0) const
 Find the first position of the string in the vector of vector, in a specific column, which is not empty. More...
 
size_type Find (const Ztring &ToFind, size_type Pos1, size_type Pos0Begin, const Ztring &Comparator, ztring_t Options=Ztring_Nothing) const
 Find the first position of the string in the vector of vector, in a specific column. More...
 
Ztring FindValue (const Ztring &ToFind, size_type Pos1Value=1, size_type Pos1=0, size_type Pos0Begin=0, const Ztring &Comparator=__T("=="), ztring_t Options=Ztring_Nothing) const
 Return [xxx][Pos1Value] when founded the first position of the string in the vector of vector, in a specific column. More...
 
ZtringListList SubSheet (const Ztring &ToFind, size_type Pos1=0, size_type Pos0Begin=0, const Ztring &Comparator=__T("=="), ztring_t Options=Ztring_Nothing) const
 Return a subsheet, with all lines with position of the string in the vector of vector, in a specific column. More...
 
void Separator_Set (size_type Level, const Ztring &NewSeparator)
 Set the Separator character. More...
 
void Quote_Set (const Ztring &NewQuote)
 Set the Quote character During Read() or Write() method, if Separator is in the sequence, we must quote it. More...
 
void Max_Set (size_type Level, size_type Max)
 Set the Maximum number of element to read During Read() or Write() method, if there is more elements, merge them with the last element. More...
 

Protected Attributes

Ztring Separator [2]
 
Ztring Quote
 
size_type Max [2]
 

Detailed Description

Vector of vectors of strings manipulation (based on std::vector<std::vector<std::(w)string>>)

Constructor & Destructor Documentation

◆ ZtringListList() [1/4]

ZenLib::ZtringListList::ZtringListList ( )

◆ ZtringListList() [2/4]

ZenLib::ZtringListList::ZtringListList ( const ZtringListList Source)

◆ ZtringListList() [3/4]

ZenLib::ZtringListList::ZtringListList ( const Ztring Source)

◆ ZtringListList() [4/4]

ZenLib::ZtringListList::ZtringListList ( const Char Source)

Member Function Documentation

◆ Delete() [1/2]

void ZenLib::ZtringListList::Delete ( const Ztring ToFind,
size_type  Pos1 = 0,
const Ztring Comparator = __T("=="),
ztring_t  Options = Ztring_Nothing 
)

Delete all vectors of string, with [xxx][Pos1] == ToFind.

◆ Delete() [2/2]

void ZenLib::ZtringListList::Delete ( size_type  Pos0)
inline

Delete a vector of string at position Pos0.

◆ Delete1()

void ZenLib::ZtringListList::Delete1 ( size_type  Pos1)

Delete a string at all positions Pos1.

◆ Find() [1/2]

size_type ZenLib::ZtringListList::Find ( const Ztring ToFind,
size_type  Pos1,
size_type  Pos0Begin,
const Ztring Comparator,
ztring_t  Options = Ztring_Nothing 
) const

Find the first position of the string in the vector of vector, in a specific column.

◆ Find() [2/2]

size_type ZenLib::ZtringListList::Find ( const Ztring ToFind,
size_type  Pos1 = 0,
size_type  Pos0Begin = 0 
) const

Find the first position of the string in the vector of vector, in a specific column.

◆ Find_Filled()

size_type ZenLib::ZtringListList::Find_Filled ( size_type  Pos1 = 0,
size_type  Pos0Begin = 0 
) const

Find the first position of the string in the vector of vector, in a specific column, which is not empty.

◆ FindValue()

Ztring ZenLib::ZtringListList::FindValue ( const Ztring ToFind,
size_type  Pos1Value = 1,
size_type  Pos1 = 0,
size_type  Pos0Begin = 0,
const Ztring Comparator = __T("=="),
ztring_t  Options = Ztring_Nothing 
) const

Return [xxx][Pos1Value] when founded the first position of the string in the vector of vector, in a specific column.

◆ Insert()

void ZenLib::ZtringListList::Insert ( const ZtringList ToInsert,
size_type  Pos0 
)
inline

Insert a vector of string at position Pos0.

◆ Insert1()

void ZenLib::ZtringListList::Insert1 ( const Ztring ToInsert,
size_type  Pos1 
)

Insert a string at all positions Pos1.

◆ Max_Set()

void ZenLib::ZtringListList::Max_Set ( size_type  Level,
size_type  Max 
)

Set the Maximum number of element to read During Read() or Write() method, if there is more elements, merge them with the last element.

◆ operator!=()

bool ZenLib::ZtringListList::operator!= ( const ZtringListList Source) const

◆ operator()() [1/4]

Ztring & ZenLib::ZtringListList::operator() ( const Ztring Pos0,
size_type  Pos0_1,
size_type  Pos1 
)

Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][Pos0_1].

◆ operator()() [2/4]

Ztring & ZenLib::ZtringListList::operator() ( const Ztring Pos0,
size_type  Pos1 = 1 
)
inline

Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][0].

References operator()().

◆ operator()() [3/4]

ZtringList & ZenLib::ZtringListList::operator() ( size_type  Pos0)

Same as [], but write a empty string if Pos doesn't exist yet.

Referenced by operator()().

◆ operator()() [4/4]

Ztring & ZenLib::ZtringListList::operator() ( size_type  Pos0,
size_type  Pos1 
)

◆ operator+=()

ZtringListList & ZenLib::ZtringListList::operator+= ( const ZtringListList Source)

◆ operator=()

ZtringListList & ZenLib::ZtringListList::operator= ( const ZtringListList Source)

◆ operator==()

bool ZenLib::ZtringListList::operator== ( const ZtringListList Source) const

◆ push_back() [1/3]

void ZenLib::ZtringListList::push_back ( const Char ToAdd)
inline

Add a vector of string (Char version)

References push_back().

Referenced by push_back().

◆ push_back() [2/3]

void ZenLib::ZtringListList::push_back ( const Ztring ToAdd)

Add a vector of string (with separator is ZtringListList Separator)

◆ push_back() [3/3]

void ZenLib::ZtringListList::push_back ( const ZtringList ToAdd)

Add a vector of string.

◆ Quote_Set()

void ZenLib::ZtringListList::Quote_Set ( const Ztring NewQuote)

Set the Quote character During Read() or Write() method, if Separator is in the sequence, we must quote it.

◆ Read() [1/7]

Ztring ZenLib::ZtringListList::Read ( ) const

Read all.

◆ Read() [2/7]

const Ztring & ZenLib::ZtringListList::Read ( const Ztring Pos0,
const Ztring Default,
size_type  Pos0_1,
size_type  Pos1 
) const

Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][Pos0_1], with default value.

◆ Read() [3/7]

const Ztring & ZenLib::ZtringListList::Read ( const Ztring Pos0,
const Ztring Default,
size_type  Pos1 = 1 
) const

Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][0], with default value.

◆ Read() [4/7]

const Ztring & ZenLib::ZtringListList::Read ( const Ztring Pos0,
size_type  Pos0_1,
size_type  Pos1 
) const

Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][Pos0_1].

◆ Read() [5/7]

const Ztring & ZenLib::ZtringListList::Read ( const Ztring Pos0,
size_type  Pos1 = 1 
) const

Return [Pos][Pos1], Pos=First occurency of Pos0 in [xxx][0].

◆ Read() [6/7]

Ztring ZenLib::ZtringListList::Read ( size_type  Pos0) const

Read a vector of string.

◆ Read() [7/7]

const Ztring & ZenLib::ZtringListList::Read ( size_type  Pos0,
size_type  Pos1 
) const

Read a string.

◆ Read1()

Ztring ZenLib::ZtringListList::Read1 ( size_type  Pos1) const

Read all strings at position Pos1.

◆ Separator_Set()

void ZenLib::ZtringListList::Separator_Set ( size_type  Level,
const Ztring NewSeparator 
)

Set the Separator character.

◆ Sort()

void ZenLib::ZtringListList::Sort ( size_type  Pos1,
ztring_t  Options = Ztring_Nothing 
)

Sort.

◆ SubSheet()

ZtringListList ZenLib::ZtringListList::SubSheet ( const Ztring ToFind,
size_type  Pos1 = 0,
size_type  Pos0Begin = 0,
const Ztring Comparator = __T("=="),
ztring_t  Options = Ztring_Nothing 
) const

Return a subsheet, with all lines with position of the string in the vector of vector, in a specific column.

◆ Swap()

void ZenLib::ZtringListList::Swap ( size_type  Pos0_A,
size_type  Pos0_B 
)

Swap 2 positions.

◆ Swap1()

void ZenLib::ZtringListList::Swap1 ( size_type  Pos1_A,
size_type  Pos1_B 
)

Swap 2 columns for each line.

◆ Write() [1/3]

void ZenLib::ZtringListList::Write ( const Ztring ToWrite)

Write all.

◆ Write() [2/3]

void ZenLib::ZtringListList::Write ( const Ztring ToWrite,
size_type  Pos0,
size_type  Pos1 
)

Write a vector of string.

◆ Write() [3/3]

void ZenLib::ZtringListList::Write ( const ZtringList ToWrite,
size_type  Pos0 
)

Write a vector of string.

Member Data Documentation

◆ Max

size_type ZenLib::ZtringListList::Max[2]
protected

◆ Quote

Ztring ZenLib::ZtringListList::Quote
protected

◆ Separator

Ztring ZenLib::ZtringListList::Separator[2]
protected

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