Standard implementation of IStringList that can represent a vector<string> type.
More...
#include <StringList.h>
Standard implementation of IStringList that can represent a vector<string> type.
◆ StringList() [1/2]
nvneural::StringList::StringList |
( |
const std::vector< std::string > & |
stringList | ) |
|
|
inlineexplicit |
Creates a StringList from a const reference.
- Parameters
-
stringList | Vector of strings to copy |
◆ StringList() [2/2]
nvneural::StringList::StringList |
( |
std::vector< std::string > && |
stringList | ) |
|
|
inlineexplicit |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Creates a StringList from an rvalue reference.
- Parameters
-
stringList | Vector of strings to move |
◆ getStringByIndex()
const char* nvneural::StringList::getStringByIndex |
( |
size_t |
stringIndex | ) |
const |
|
inlinenoexcept |
Returns the Nth string in the collection.
Pointers returned by this method are guaranteed to be valid until the IStringList is freed. If the string index is within the half-open range [0, stringIndex) the return value will not be a null pointer.
- Parameters
-
stringIndex | Index of the string to retrieve |
- Returns
- The requested string, or nullptr if stringIndex is out of range.
◆ getStringSizeByIndex()
size_t nvneural::StringList::getStringSizeByIndex |
( |
size_t |
stringIndex | ) |
const |
|
inlinenoexcept |
Returns the Nth string's size in the collection.
If the string index is not within the half-open range [0, stringIndex) the return value will be 0.
- Parameters
-
stringIndex | Index of the string's size to retrieve |
- Returns
- The requested string size, or 0 if stringIndex is out of range.
◆ stringCount()
size_t nvneural::StringList::stringCount |
( |
| ) |
const |
|
inlinenoexcept |
- Returns
- The number of strings in this collection.
The documentation for this class was generated from the following file: