hops
Public Types | Public Member Functions | List of all members
HighFive::FixedLenStringArray< N > Class Template Reference

A structure representing a set of fixed-length strings. More...

#include <H5_definitions.hpp>

Collaboration diagram for HighFive::FixedLenStringArray< N >:
Collaboration graph

Public Types

using iterator = typename vector_t::iterator
 
using const_iterator = typename vector_t::const_iterator
 
using reverse_iterator = typename vector_t::reverse_iterator
 
using const_reverse_iterator = typename vector_t::const_reverse_iterator
 
using value_type = typename vector_t::value_type
 

Public Member Functions

 FixedLenStringArray ()=default
 
 FixedLenStringArray (const char array[][N], std::size_t length)
 Create a FixedStringArray from a raw contiguous buffer. More...
 
 FixedLenStringArray (const std::vector< std::string > &vec)
 Create a FixedStringArray from a sequence of strings. More...
 
 FixedLenStringArray (const std::string *iter_begin, const std::string *iter_end)
 
 FixedLenStringArray (const std::initializer_list< std::string > &)
 
void push_back (const std::string &)
 Append an std::string to the buffer structure. More...
 
void push_back (const std::array< char, N > &)
 
std::string getString (std::size_t index) const
 Retrieve a string from the structure as std::string. More...
 
const char * operator[] (std::size_t i) const noexcept
 
const char * at (std::size_t i) const
 
bool empty () const noexcept
 
std::size_t size () const noexcept
 
void resize (std::size_t n)
 
const char * front () const
 
const char * back () const
 
char * data () noexcept
 
const char * data () const noexcept
 
iterator begin () noexcept
 
iterator end () noexcept
 
const_iterator begin () const noexcept
 
const_iterator cbegin () const noexcept
 
const_iterator end () const noexcept
 
const_iterator cend () const noexcept
 
reverse_iterator rbegin () noexcept
 
reverse_iterator rend () noexcept
 
const_reverse_iterator rbegin () const noexcept
 
const_reverse_iterator rend () const noexcept
 

Detailed Description

template<std::size_t N>
class HighFive::FixedLenStringArray< N >

A structure representing a set of fixed-length strings.

Although fixed-len arrays can be created 'raw' without the need for this structure, to retrieve results efficiently it must be used.

Member Typedef Documentation

◆ const_iterator

template<std::size_t N>
using HighFive::FixedLenStringArray< N >::const_iterator = typename vector_t::const_iterator

◆ const_reverse_iterator

template<std::size_t N>
using HighFive::FixedLenStringArray< N >::const_reverse_iterator = typename vector_t::const_reverse_iterator

◆ iterator

template<std::size_t N>
using HighFive::FixedLenStringArray< N >::iterator = typename vector_t::iterator

◆ reverse_iterator

template<std::size_t N>
using HighFive::FixedLenStringArray< N >::reverse_iterator = typename vector_t::reverse_iterator

◆ value_type

template<std::size_t N>
using HighFive::FixedLenStringArray< N >::value_type = typename vector_t::value_type

Constructor & Destructor Documentation

◆ FixedLenStringArray() [1/5]

template<std::size_t N>
HighFive::FixedLenStringArray< N >::FixedLenStringArray ( )
default

◆ FixedLenStringArray() [2/5]

template<std::size_t N>
HighFive::FixedLenStringArray< N >::FixedLenStringArray ( const char  array[][N],
std::size_t  length 
)
inline

Create a FixedStringArray from a raw contiguous buffer.

◆ FixedLenStringArray() [3/5]

template<std::size_t N>
HighFive::FixedLenStringArray< N >::FixedLenStringArray ( const std::vector< std::string > &  vec)
inlineexplicit

Create a FixedStringArray from a sequence of strings.

Such conversion involves a copy, original vector is not modified

◆ FixedLenStringArray() [4/5]

template<std::size_t N>
HighFive::FixedLenStringArray< N >::FixedLenStringArray ( const std::string iter_begin,
const std::string iter_end 
)
inline

◆ FixedLenStringArray() [5/5]

template<std::size_t N>
HighFive::FixedLenStringArray< N >::FixedLenStringArray ( const std::initializer_list< std::string > &  init_list)
inline

Member Function Documentation

◆ at()

template<std::size_t N>
const char* HighFive::FixedLenStringArray< N >::at ( std::size_t  i) const
inline

◆ back()

template<std::size_t N>
const char* HighFive::FixedLenStringArray< N >::back ( ) const
inline

◆ begin() [1/2]

template<std::size_t N>
const_iterator HighFive::FixedLenStringArray< N >::begin ( ) const
inlinenoexcept

◆ begin() [2/2]

template<std::size_t N>
iterator HighFive::FixedLenStringArray< N >::begin ( )
inlinenoexcept

◆ cbegin()

template<std::size_t N>
const_iterator HighFive::FixedLenStringArray< N >::cbegin ( ) const
inlinenoexcept

◆ cend()

template<std::size_t N>
const_iterator HighFive::FixedLenStringArray< N >::cend ( ) const
inlinenoexcept

◆ data() [1/2]

template<std::size_t N>
const char* HighFive::FixedLenStringArray< N >::data ( ) const
inlinenoexcept

◆ data() [2/2]

template<std::size_t N>
char* HighFive::FixedLenStringArray< N >::data ( )
inlinenoexcept

◆ empty()

template<std::size_t N>
bool HighFive::FixedLenStringArray< N >::empty ( ) const
inlinenoexcept

◆ end() [1/2]

template<std::size_t N>
const_iterator HighFive::FixedLenStringArray< N >::end ( ) const
inlinenoexcept

◆ end() [2/2]

template<std::size_t N>
iterator HighFive::FixedLenStringArray< N >::end ( )
inlinenoexcept

◆ front()

template<std::size_t N>
const char* HighFive::FixedLenStringArray< N >::front ( ) const
inline

◆ getString()

template<std::size_t N>
std::string HighFive::FixedLenStringArray< N >::getString ( std::size_t  index) const
inline

Retrieve a string from the structure as std::string.

◆ operator[]()

template<std::size_t N>
const char* HighFive::FixedLenStringArray< N >::operator[] ( std::size_t  i) const
inlinenoexcept

◆ push_back() [1/2]

template<std::size_t N>
void HighFive::FixedLenStringArray< N >::push_back ( const std::array< char, N > &  src)
inline

◆ push_back() [2/2]

template<std::size_t N>
void HighFive::FixedLenStringArray< N >::push_back ( const std::string src)
inline

Append an std::string to the buffer structure.

◆ rbegin() [1/2]

template<std::size_t N>
const_reverse_iterator HighFive::FixedLenStringArray< N >::rbegin ( ) const
inlinenoexcept

◆ rbegin() [2/2]

template<std::size_t N>
reverse_iterator HighFive::FixedLenStringArray< N >::rbegin ( )
inlinenoexcept

◆ rend() [1/2]

template<std::size_t N>
const_reverse_iterator HighFive::FixedLenStringArray< N >::rend ( ) const
inlinenoexcept

◆ rend() [2/2]

template<std::size_t N>
reverse_iterator HighFive::FixedLenStringArray< N >::rend ( )
inlinenoexcept

◆ resize()

template<std::size_t N>
void HighFive::FixedLenStringArray< N >::resize ( std::size_t  n)
inline

◆ size()

template<std::size_t N>
std::size_t HighFive::FixedLenStringArray< N >::size ( ) const
inlinenoexcept

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