30inline char* Foam::CStringList::stringCopy(
char *dest,
const std::string& src)
33 const size_t len = src.length();
34 for (
size_t i = 0; i < len; ++i)
72template<
class StringType>
81template<
class StringType>
138 return &(argv_[start]);
142template<
class StringType>
145 return resetContent(
input);
149template<
class StringType>
152 return resetContent(
input);
An adapter for copying a list of C++ strings into a list of C-style strings for passing to C code tha...
~CStringList()
Destructor. Invokes clear() to free memory.
int size() const noexcept
Return the number of C-strings (ie, argc)
const char * operator[](int i) const
Return element at the given index. No bounds checking.
constexpr CStringList() noexcept
Default construct, adding content later (via reset).
bool empty() const noexcept
True if the size (ie, argc) is zero.
char ** strings() const noexcept
Return the list of C-strings (ie, argv)
int reset(const UList< StringType > &input)
Copy the input list of strings.
void clear()
Clear contents and free memory.
unsigned int get() const
Get value as unsigned, no range-checking.
Sub-ranges of a string with a structure similar to std::match_results, but without the underlying reg...
A 1D vector of objects of type <T>, where the size of the vector is known and can be used for subscri...
void reset()
Reset to defaults.
static Istream & input(Istream &is, IntRange< T > &range)