8 #include "Arp/Plc/Commons/Meta/ArrayDimension.hpp"
11 #include <initializer_list>
13 namespace Arp {
namespace Plc {
namespace Commons {
namespace Meta
19 friend class ArrayNavigator;
22 using Values = std::vector<ArrayDimension>;
56 bool IsEmpty(
void)
const;
61 const Values& GetValues(
void)
const;
75 void EraseFrontDimension(
void);
100 return this->values[index];
103 inline const ArrayDimension& ArrayDimensions::operator[](
size_t index)
const
105 return this->values[index];
108 inline bool ArrayDimensions::IsEmpty()
const
110 return this->values.empty();
115 return this->values.size();
118 inline const ArrayDimensions::Values& ArrayDimensions::GetValues()
const
123 inline void ArrayDimensions::EraseFrontDimension(
void)
125 if (this->values.size() > 0)
127 this->values.erase(this->values.begin());
131 inline void ArrayDimensions::Append(
const ArrayDimension& dimension)
133 this->values.push_back(dimension);
144 std::equal(lhs.GetValues().begin(), lhs.GetValues().end(), rhs.GetValues().begin());
147 inline bool operator!= (
const ArrayDimensions& lhs,
const ArrayDimensions& rhs)
149 return !(lhs == rhs);
152 inline std::ostream&
operator<<(std::ostream& os,
const ArrayDimensions& rhs)
154 if (rhs.GetCount() == 0)
161 const auto count = rhs.GetCount();
162 for (
size_t i = 1; i < count; ++i)
std::ostream & operator<<(std::ostream &os, const BasicString< CharType, Alloc > &right)
Streams the right string to the outstream os .
Definition: BasicString.hxx:1708
bool operator!=(const BasicString< CharType, Alloc > &left, const BasicString< CharType, Alloc > &right)
Compares the left string to the right string on inequality.
Definition: BasicString.hxx:1912
bool operator==(const BasicString< CharType, Alloc > &left, const BasicString< CharType, Alloc > &right)
Compares the left string to the right string on equality.
Definition: BasicString.hxx:1876
Root namespace for the PLCnext API