PCL
pcl::IsoString Class Reference

Eight-bit string (ISO/IEC-8859-1 or UTF-8 string) More...

#include <String.h>

+ Inheritance diagram for pcl::IsoString:

Public Types

typedef string_base::allocator allocator
 
typedef string_base::block_allocator block_allocator
 
typedef string_base::c_string c_string
 
typedef ustring_base::c_string c_ustring
 
typedef string_base::char_traits char_traits
 
typedef string_base::char_type char_type
 
typedef string_base::const_c_string const_c_string
 
typedef ustring_base::const_c_string const_c_ustring
 
typedef string_base::const_iterator const_iterator
 
typedef string_base::const_reverse_iterator const_reverse_iterator
 
typedef ustring_base::const_iterator const_uchar_iterator
 
typedef string_base::iterator iterator
 
typedef string_base::reverse_iterator reverse_iterator
 
typedef GenericString< char, IsoCharTraits, StandardAllocatorstring_base
 
typedef ustring_base::iterator uchar_iterator
 
typedef ustring_base::char_traits uchar_traits
 
typedef ustring_base::char_type uchar_type
 
typedef GenericString< char16_type, CharTraits, StandardAllocatorustring_base
 
- Public Types inherited from pcl::GenericString< char, IsoCharTraits, StandardAllocator >
typedef pcl::Allocator< char, StandardAllocatorallocator
 
typedef StandardAllocator block_allocator
 
typedef char * c_string
 
typedef IsoCharTraits char_traits
 
typedef char char_type
 
typedef const char * const_c_string
 
typedef const char * const_iterator
 
typedef ReverseRandomAccessIterator< const_iterator, const char > const_reverse_iterator
 
typedef char * iterator
 
typedef ReverseRandomAccessIterator< iterator, char > reverse_iterator
 

Public Member Functions

 IsoString ()
 
 IsoString (const string_base &s)
 
 IsoString (const IsoString &s)
 
 IsoString (string_base &&s)
 
 IsoString (const IsoString &&s)
 
 IsoString (const ustring_base &s)
 
 IsoString (const_c_string t)
 
 IsoString (const_c_string t, size_type i, size_type n)
 
 IsoString (char_type c, size_type n=1)
 
 IsoString (const_iterator i, const_iterator j)
 
 IsoString (std::initializer_list< char_type > l)
 
 IsoString (const_c_ustring t)
 
 IsoString (const_c_ustring t, size_type i, size_type n)
 
 IsoString (const ByteArray &B)
 
 IsoString (bool x)
 
 IsoString (short x)
 
 IsoString (unsigned short x)
 
 IsoString (int x)
 
 IsoString (unsigned int x)
 
 IsoString (long x)
 
 IsoString (unsigned long x)
 
 IsoString (long long x)
 
 IsoString (unsigned long long x)
 
 IsoString (float x)
 
 IsoString (double x)
 
 IsoString (long double x)
 
 IsoString (Complex< float > &x)
 
 IsoString (Complex< double > &x)
 
 IsoString (Complex< long double > &x)
 
IsoStringAppendFormat (const_c_string fmt,...)
 
int AppendVFormat (const_c_string fmt, va_list paramList)
 
IsoString DecodedHTMLSpecialChars () const
 
IsoString EncodedHTMLSpecialChars () const
 
IsoStringFormat (const_c_string fmt,...)
 
ByteArray FromBase64 () const
 
ByteArray FromHex () const
 
ByteArray FromURLEncoded () const
 
ustring_base MBSToWCS () const
 
IsoStringoperator= (const IsoString &s)
 
IsoStringoperator= (IsoString &&s)
 
IsoStringoperator= (const string_base &s)
 
IsoStringoperator= (string_base &&s)
 
IsoStringoperator= (const ustring_base &s)
 
IsoStringoperator= (const_c_string t)
 
IsoStringoperator= (char_type c)
 
IsoStringoperator= (const_c_ustring t)
 
void ParseISO8601DateTime (int &year, int &month, int &day, double &dayf, double &tz) const
 
void ParseSexagesimal (int &sign, int &s1, int &s2, double &s3, const IsoString &separator=':') const
 
void ParseSexagesimal (int &sign, int &s1, int &s2, double &s3, const Array< char_type > &separators) const
 
double SexagesimalToDouble (const IsoString &separator=':') const
 
double SexagesimalToDouble (const Array< char_type > &separators) const
 
bool ToBool () const
 
ByteArray ToByteArray () const
 
template<class C >
IsoStringToColonSeparated (const C &c)
 
template<class C >
IsoStringToCommaSeparated (const C &c)
 
IsoStringToDecodedHTMLSpecialChars ()
 
double ToDouble () const
 
IsoStringToEncodedHTMLSpecialChars ()
 
float ToFloat () const
 
template<class C >
IsoStringToHyphenated (const C &c)
 
long ToInt () const
 
long ToInt (int base) const
 
long long ToInt64 () const
 
long long ToInt64 (int base) const
 
template<class C >
IsoStringToNewLineSeparated (const C &c)
 
template<class C >
IsoStringToNullSeparated (const C &c)
 
template<class C >
IsoStringToSeparated (const C &c, char_type separator)
 
template<class C , class AF >
IsoStringToSeparated (const C &c, char_type separator, AF append)
 
template<class C >
IsoStringToSeparated (const C &c, const IsoString &separator)
 
template<class C , class AF >
IsoStringToSeparated (const C &c, const IsoString &separator, AF append)
 
template<class C >
IsoStringToSeparated (const C &c, const_c_string separator)
 
template<class C , class AF >
IsoStringToSeparated (const C &c, const_c_string separator, AF append)
 
template<class C >
IsoStringToSpaceSeparated (const C &c)
 
ustring_base ToString () const
 
template<class C >
IsoStringToTabSeparated (const C &c)
 
unsigned long ToUInt () const
 
unsigned long ToUInt (int base) const
 
unsigned long long ToUInt64 () const
 
unsigned long long ToUInt64 (int base) const
 
IsoStringToURLDecoded ()
 
IsoStringToURLEncoded ()
 
bool TryParseISO8601DateTime (int &year, int &month, int &day, double &dayf, double &tz) const
 
bool TryParseSexagesimal (int &sign, int &s1, int &s2, double &s3, const IsoString &separator=':') const
 
bool TryParseSexagesimal (int &sign, int &s1, int &s2, double &s3, const Array< char_type > &separators) const
 
bool TrySexagesimalToDouble (double &value, const IsoString &separator=':') const
 
bool TrySexagesimalToDouble (double &value, const Array< char_type > &separators) const
 
bool TryToBool (bool &value) const
 
bool TryToDouble (double &value) const
 
bool TryToFloat (float &value) const
 
bool TryToInt (int &value) const
 
bool TryToInt (int &value, int base) const
 
bool TryToInt64 (long long &value) const
 
bool TryToInt64 (long long &value, int base) const
 
bool TryToUInt (unsigned &value) const
 
bool TryToUInt (unsigned &value, int base) const
 
bool TryToUInt64 (unsigned long long &value) const
 
bool TryToUInt64 (unsigned long long &value, int base) const
 
IsoString URLDecoded () const
 
IsoString URLEncoded () const
 
ustring_base UTF8ToUTF16 (size_type i=0, size_type n=maxPos) const
 
int VFormat (const_c_string fmt, va_list paramList)
 
- Public Member Functions inherited from pcl::GenericString< char, IsoCharTraits, StandardAllocator >
 GenericString ()
 
 GenericString (const GenericString &s)
 
 GenericString (GenericString &&s)
 
 GenericString (const_c_string t)
 
 GenericString (const_iterator i, const_iterator j)
 
 GenericString (std::initializer_list< char_type > l)
 
 GenericString (const_c_string t, size_type i, size_type n)
 
 GenericString (char_type c, size_type n=1)
 
 ~GenericString ()
 
void Add (const GenericString< char, R1, A1 > &s)
 
void Add (const_iterator i, const_iterator j)
 
void Add (const_c_string t, size_type n)
 
void Add (const_c_string t)
 
void Add (char_type c, size_type n=1)
 
void Append (const GenericString< char, R1, A1 > &s)
 
void Append (const_iterator i, const_iterator j)
 
void Append (const_c_string t, size_type n)
 
void Append (const_c_string t)
 
void Append (char_type c, size_type n=1)
 
void Assign (const GenericString &s)
 
void Assign (const GenericString &s, size_type i, size_type n)
 
void Assign (const_c_string t)
 
void Assign (const_iterator i, const_iterator j)
 
void Assign (std::initializer_list< char_type > l)
 
void Assign (const_c_string t, size_type i, size_type n)
 
void Assign (char_type c, size_type n=1)
 
iterator At (size_type i)
 
const_iterator At (size_type i) const
 
size_type Available () const
 
iterator Begin ()
 
const_iterator Begin () const
 
iterator begin ()
 
const_iterator begin () const
 
size_type Break (C &list, const GenericString< char, R1, A1 > &s, bool trim=false, size_type i=0) const
 
size_type Break (C &list, const_c_string s, bool trim=false, size_type i=0) const
 
size_type Break (C &list, char_type c, bool trim=false, size_type i=0) const
 
size_type Break (C &list, const Array< S > &ca, bool trim=false, size_type i=0) const
 
size_type BreakIC (C &list, const GenericString< char, R1, A1 > &s, bool trim=false, size_type i=0) const
 
size_type BreakIC (C &list, const_c_string s, bool trim=false, size_type i=0) const
 
size_type BreakIC (C &list, char_type c, bool trim=false, size_type i=0) const
 
void c_copy (iterator dst, size_type maxCharsToCopy, size_type i=0) const
 
const_c_string c_str () const
 
size_type Capacity () const
 
GenericString CaseFolded () const
 
GenericString CenterJustified (size_type width, char_type fill=IsoCharTraits ::Blank()) const
 
void Clear ()
 
int Compare (const GenericString< char, R1, A1 > &s, bool caseSensitive=true, bool localeAware=true) const
 
int Compare (const_c_string t, bool caseSensitive=true, bool localeAware=true) const
 
int Compare (char_type c, bool caseSensitive=true, bool localeAware=true) const
 
int CompareCodePoints (const GenericString< char, R1, A1 > &s, bool caseSensitive=true) const
 
int CompareCodePoints (const_c_string t, bool caseSensitive=true) const
 
int CompareCodePoints (char_type c, bool caseSensitive=true) const
 
int CompareIC (const GenericString< char, R1, A1 > &s, bool localeAware=true) const
 
int CompareIC (const_c_string t, bool localeAware=true) const
 
int CompareIC (char_type c, bool localeAware=true) const
 
bool Contains (const GenericString< char, R1, A1 > &s) const
 
bool Contains (const_c_string t) const
 
bool Contains (char_type c) const
 
bool ContainsIC (const GenericString< char, R1, A1 > &s) const
 
bool ContainsIC (const_c_string t) const
 
bool ContainsIC (char_type c) const
 
void Delete (size_type i, size_type n=1)
 
void DeleteChar (char_type c, size_type i=0)
 
void DeleteCharIC (char_type c, size_type i=0)
 
void DeleteLeft (size_type i)
 
void DeleteRight (size_type i)
 
void DeleteString (const GenericString< char, R1, A1 > &s, size_type i=0)
 
void DeleteString (const_c_string t, size_type i=0)
 
void DeleteStringIC (const GenericString< char, R1, A1 > &s, size_type i=0)
 
void DeleteStringIC (const_c_string t, size_type i=0)
 
GenericString DoubleQuoted () const
 
GenericString Enclosed (char_type c) const
 
iterator End ()
 
const_iterator End () const
 
iterator end ()
 
const_iterator end () const
 
bool EndsWith (const GenericString< char, R1, A1 > &s) const
 
bool EndsWith (const_c_string t) const
 
bool EndsWith (char_type c) const
 
bool EndsWithIC (const GenericString< char, R1, A1 > &s) const
 
bool EndsWithIC (const_c_string t) const
 
bool EndsWithIC (char_type c) const
 
void EnsureDoubleQuoted ()
 
void EnsureEnclosed (char_type c)
 
void EnsureSingleQuoted ()
 
void EnsureUnique ()
 
void Fill (char_type c)
 
void Fill (char_type c, size_type i, size_type n=maxPos)
 
size_type Find (const GenericString< char, R1, A1 > &s, size_type i=0) const
 
size_type Find (const_c_string t, size_type i=0) const
 
size_type Find (char_type c, size_type i=0) const
 
size_type FindFirst (const GenericString< char, R1, A1 > &s, size_type i=0) const
 
size_type FindFirst (const_c_string t, size_type i=0) const
 
size_type FindFirst (char_type c, size_type i=0) const
 
size_type FindFirstIC (const GenericString< char, R1, A1 > &s, size_type i=0) const
 
size_type FindFirstIC (const_c_string t, size_type i=0) const
 
size_type FindFirstIC (char_type c, size_type i=0) const
 
size_type FindIC (const GenericString< char, R1, A1 > &s, size_type i=0) const
 
size_type FindIC (const_c_string t, size_type i=0) const
 
size_type FindIC (char_type c, size_type i=0) const
 
size_type FindLast (const GenericString< char, R1, A1 > &s, size_type r=maxPos) const
 
size_type FindLast (const_c_string t, size_type r=maxPos) const
 
size_type FindLast (char_type c, size_type r=maxPos) const
 
size_type FindLastIC (const GenericString< char, R1, A1 > &s, size_type r=maxPos) const
 
size_type FindLastIC (const_c_string t, size_type r=maxPos) const
 
size_type FindLastIC (char_type c, size_type r=maxPos) const
 
char_type FirstChar () const
 
const allocatorGetAllocator () const
 
uint64 Hash (uint64 seed=0) const
 
uint32 Hash32 (uint32 seed=0) const
 
uint64 Hash64 (uint64 seed=0) const
 
bool HasWildcards () const
 
size_type IndexAt (const_iterator i) const
 
void Insert (size_type i, const GenericString< char, R1, A1 > &s)
 
void Insert (size_type i, const_iterator p, const_iterator q)
 
void Insert (size_type i, const_c_string t)
 
void Insert (size_type i, const_c_string t, size_type n)
 
void Insert (size_type i, char_type c, size_type n=1)
 
bool IsAliasOf (const GenericString &s) const
 
bool IsEmpty () const
 
bool IsNumeral () const
 
bool IsSymbol () const
 
bool IsUnique () const
 
bool IsValid () const
 
bool IsValidIdentifier (distance_type &pos) const
 
bool IsValidIdentifier () const
 
void JustifyCenter (size_type width, char_type fill=IsoCharTraits ::Blank())
 
void JustifyLeft (size_type width, char_type fill=IsoCharTraits ::Blank())
 
void JustifyRight (size_type width, char_type fill=IsoCharTraits ::Blank())
 
char_type LastChar () const
 
GenericString Left (size_type n) const
 
GenericString LeftJustified (size_type width, char_type fill=IsoCharTraits ::Blank()) const
 
size_type Length () const
 
size_type LowerBound () const
 
GenericString Lowercase () const
 
char_typeoperator* ()
 
char_type operator* () const
 
GenericStringoperator+= (const GenericString< char, R1, A1 > &s)
 
GenericStringoperator+= (const_c_string t)
 
GenericStringoperator+= (char_type c)
 
GenericStringoperator-= (const GenericString< char, R1, A1 > &s)
 
GenericStringoperator-= (const_c_string t)
 
GenericStringoperator-= (char_type c)
 
GenericStringoperator= (const GenericString &s)
 
GenericStringoperator= (GenericString &&s)
 
GenericStringoperator= (const_c_string t)
 
GenericStringoperator= (char_type c)
 
char_typeoperator[] (size_type i)
 
char_type operator[] (size_type i) const
 
GenericString Prefix (size_type i) const
 
void Prepend (const GenericString< char, R1, A1 > &s)
 
void Prepend (const_iterator i, const_iterator j)
 
void Prepend (const_c_string t, size_type n)
 
void Prepend (const_c_string t)
 
void Prepend (char_type c, size_type n=1)
 
c_string Release ()
 
void Replace (size_type i, size_type n, const GenericString< char, R1, A1 > &s)
 
void Replace (size_type i, size_type n, const_c_string t)
 
void Replace (size_type i, size_type n, char_type c, size_type nc=1)
 
void ReplaceChar (char_type c1, char_type c2, size_type i=0, size_type n=maxPos)
 
void ReplaceCharIC (char_type c1, char_type c2, size_type i=0, size_type n=maxPos)
 
void ReplaceString (const GenericString< char, R1, A1 > &s1, const GenericString< char, R2, A2 > &s2, size_type i=0)
 
void ReplaceString (const_c_string t1, const_c_string t2, size_type i=0)
 
void ReplaceStringIC (const GenericString< char, R1, A1 > &s1, const GenericString< char, R2, A2 > &s2, size_type i=0)
 
void ReplaceStringIC (const_c_string t1, const_c_string t2, size_type i=0)
 
void Reserve (size_type n)
 
GenericString ResizedToNullTerminated () const
 
void ResizeToNullTerminated ()
 
void Reverse ()
 
reverse_iterator ReverseBegin ()
 
const_reverse_iterator ReverseBegin () const
 
GenericString Reversed () const
 
reverse_iterator ReverseEnd ()
 
const_reverse_iterator ReverseEnd () const
 
GenericString Right (size_type n) const
 
GenericString RightJustified (size_type width, char_type fill=IsoCharTraits ::Blank()) const
 
void SecureFill (char c='\0')
 
void SetAllocator (const allocator &a)
 
void SetLength (size_type n)
 
GenericString SetToLength (size_type n) const
 
GenericString SingleQuoted () const
 
size_type Size () const
 
void Sort ()
 
void Sort (BP p)
 
GenericString Sorted () const
 
GenericString Sorted (BP p) const
 
void Squeeze ()
 
GenericString Squeezed () const
 
bool StartsWith (const GenericString< char, R1, A1 > &s) const
 
bool StartsWith (const_c_string t) const
 
bool StartsWith (char_type c) const
 
bool StartsWithIC (const GenericString< char, R1, A1 > &s) const
 
bool StartsWithIC (const_c_string t) const
 
bool StartsWithIC (char_type c) const
 
GenericString Substring (size_type i, size_type n=maxPos) const
 
GenericString Suffix (size_type i) const
 
void Swap (GenericString &s)
 
void ToCaseFolded ()
 
void ToLowercase ()
 
void ToUppercase ()
 
void Transfer (GenericString &s)
 
void Transfer (GenericString &&s)
 
void Trim ()
 
void TrimLeft ()
 
GenericString Trimmed () const
 
GenericString TrimmedLeft () const
 
GenericString TrimmedRight () const
 
void TrimRight ()
 
void Unquote ()
 
GenericString Unquoted () const
 
size_type UpperBound () const
 
GenericString Uppercase () const
 
bool WildMatch (const GenericString< char, R1, A1 > &pattern, bool caseSensitive=true) const
 
bool WildMatch (const_c_string pattern, bool caseSensitive=true) const
 
bool WildMatchIC (const GenericString< char, R1, A1 > &pattern) const
 
bool WildMatchIC (const_c_string pattern) const
 

Static Public Member Functions

static IsoString CurrentLocalISO8601DateTime (const ISO8601ConversionOptions &options=ISO8601ConversionOptions())
 
static IsoString CurrentUTCISO8601DateTime (const ISO8601ConversionOptions &options=ISO8601ConversionOptions())
 
static ByteArray FromURLEncoded (const void *data, size_type length)
 
template<class C >
static ByteArray FromURLEncoded (const C &c)
 
static IsoString Random (size_type n, RandomizationOptions options=RandomizationOption::Default)
 
static IsoString ToBase64 (const void *data, size_type length)
 
template<class C >
static IsoString ToBase64 (const C &c)
 
static IsoString ToHex (const void *data, size_type length)
 
template<class C >
static IsoString ToHex (const C &c)
 
static IsoString ToISO8601DateTime (int year, int month, int day, double dayf, double tz=0, const ISO8601ConversionOptions &options=ISO8601ConversionOptions())
 
static IsoString ToSexagesimal (int sign, double s1, double s2, double s3, const SexagesimalConversionOptions &options=SexagesimalConversionOptions())
 
static IsoString ToSexagesimal (double d, const SexagesimalConversionOptions &options=SexagesimalConversionOptions())
 
static IsoString ToURLDecoded (const void *data, size_type length)
 
template<class C >
static IsoString ToURLDecoded (const C &c)
 
static IsoString ToURLEncoded (const void *data, size_type length)
 
template<class C >
static IsoString ToURLEncoded (const C &c)
 
static IsoString UUID ()
 
- Static Public Member Functions inherited from pcl::GenericString< char, IsoCharTraits, StandardAllocator >
static size_type BytesPerChar ()
 
static size_type DeleteFreeList ()
 

Additional Inherited Members

- Static Public Attributes inherited from pcl::GenericString< char, IsoCharTraits, StandardAllocator >
static const size_type maxPos
 
static const size_type notFound
 

Detailed Description

IsoString derives from a template instantiation of GenericString for the char type. On the PixInsight platform, IsoString represents a dynamic ISO/IEC-8859-1 string, an 8-bit Unicode Transformation Format (UTF-8) string, or even a sequence of ASCII (or Latin-1) characters, depending on the context and type of transformations applied.

See also
String

Definition at line 5387 of file String.h.

Member Typedef Documentation

◆ allocator

The allocator class used by this template instantiation.

Definition at line 5415 of file String.h.

◆ block_allocator

The block allocator used by this template instantiation.

Definition at line 5410 of file String.h.

◆ c_string

Null-terminated sequence of 8-bit characters.

Definition at line 5420 of file String.h.

◆ c_ustring

Null-terminated sequence of UTF-16 characters.

Definition at line 5468 of file String.h.

◆ char_traits

The character traits class used by this template instantiation.

Definition at line 5405 of file String.h.

◆ char_type

Represents a character pertaining to an IsoString object.

Definition at line 5400 of file String.h.

◆ const_c_string

Immutable null-terminated sequence of 8-bit characters.

Definition at line 5425 of file String.h.

◆ const_c_ustring

Immutable null-terminated sequence of UTF-16 characters.

Definition at line 5473 of file String.h.

◆ const_iterator

Immutable IsoString iterator.

Definition at line 5435 of file String.h.

◆ const_reverse_iterator

Immutable reverse IsoString iterator.

Definition at line 5445 of file String.h.

◆ const_uchar_iterator

Immutable Unicode (UTF-16) string iterator.

Definition at line 5483 of file String.h.

◆ iterator

IsoString iterator.

Definition at line 5430 of file String.h.

◆ reverse_iterator

Reverse IsoString iterator.

Definition at line 5440 of file String.h.

◆ string_base

Base class of IsoString.

Definition at line 5395 of file String.h.

◆ uchar_iterator

Unicode (UTF-16) string iterator.

Definition at line 5478 of file String.h.

◆ uchar_traits

Unicode (UTF-16) character traits class.

Definition at line 5463 of file String.h.

◆ uchar_type

Represents a Unicode (UTF-16) character.

Definition at line 5458 of file String.h.

◆ ustring_base

Represents a Unicode (UTF-16) string.

Note
This type must be defined as the same template instantiation used for the String class.

Definition at line 5453 of file String.h.

Constructor & Destructor Documentation

◆ IsoString() [1/29]

pcl::IsoString::IsoString ( )
inline

Constructs an empty IsoString object.

Definition at line 5490 of file String.h.

◆ IsoString() [2/29]

pcl::IsoString::IsoString ( const string_base s)
inline

Constructs an IsoString object as a shallow copy of the specified string_base string s (copy constructor from the base class).

Definition at line 5498 of file String.h.

◆ IsoString() [3/29]

pcl::IsoString::IsoString ( const IsoString s)
inline

Copy constructor.

Definition at line 5505 of file String.h.

◆ IsoString() [4/29]

pcl::IsoString::IsoString ( string_base &&  s)
inline

Constructs an IsoString object by transferring data from the specified string_base string s (move constructor from the base class).

Definition at line 5513 of file String.h.

◆ IsoString() [5/29]

pcl::IsoString::IsoString ( const IsoString &&  s)
inline

Move constructor.

Definition at line 5520 of file String.h.

◆ IsoString() [6/29]

pcl::IsoString::IsoString ( const ustring_base s)
inlineexplicit

Constructs an IsoString as a copy of the specified Unicode string s, transformed to ISO/IEC-8859-1. Characters in the Unicode string that cannot be converted to ISO/IEC-8859-1 (that is, code points greater than 0x100) will have undefined values in the 8-bit string. Undefined values are represented with question mark characters (?).

Definition at line 5532 of file String.h.

◆ IsoString() [7/29]

pcl::IsoString::IsoString ( const_c_string  t)
inline

Constructs an IsoString as a copy of a null-terminated string t.

Definition at line 5540 of file String.h.

◆ IsoString() [8/29]

pcl::IsoString::IsoString ( const_c_string  t,
size_type  i,
size_type  n 
)
inline

Constructs an IsoString with the n first characters of the null-terminated string t, starting from its i-th character.

Definition at line 5548 of file String.h.

◆ IsoString() [9/29]

pcl::IsoString::IsoString ( char_type  c,
size_type  n = 1 
)
inline

Constructs an IsoString with n copies of a character c.

Definition at line 5555 of file String.h.

◆ IsoString() [10/29]

pcl::IsoString::IsoString ( const_iterator  i,
const_iterator  j 
)
inline

Constructs an IsoString with a copy of the character sequence defined by the range [i,j).

Definition at line 5563 of file String.h.

◆ IsoString() [11/29]

pcl::IsoString::IsoString ( std::initializer_list< char_type l)
inline

Constructs an IsoString with a copy of the character sequence stored in the specified initializer list l.

This constructor is equivalent to:

IsoString( l.begin(), l.end() )

Definition at line 5575 of file String.h.

◆ IsoString() [12/29]

pcl::IsoString::IsoString ( const_c_ustring  t)
inlineexplicit

Constructs an IsoString as a copy of the null-terminated Unicode (UTF-16) string t, transformed to ISO/IEC-8859-1.

If the specified Unicode string t contains characters that cannot be converted to ISO/IEC-8859-1 characters, the corresponding characters in this string will have undefined values. For conversions from UTF-16 to UTF-8, see String::ToUTF8() and String::UTF16ToUTF8().

Definition at line 5589 of file String.h.

◆ IsoString() [13/29]

pcl::IsoString::IsoString ( const_c_ustring  t,
size_type  i,
size_type  n 
)
inline

Constructs an IsoString with the n first characters of the null-terminated Unicode (UTF-16) string t, starting from its i-th character, transformed to ISO/IEC-8859-1.

If the specified Unicode string t contains characters that cannot be converted to ISO/IEC-8859-1 characters, the corresponding characters in this string will have undefined values. For conversions from UTF-16 to UTF-8, see String::ToUTF8() and String::UTF16ToUTF8().

Definition at line 11991 of file String.h.

References pcl::GenericString< char, IsoCharTraits, StandardAllocator >::end(), pcl::CharTraits::Length(), and pcl::Min().

◆ IsoString() [14/29]

pcl::IsoString::IsoString ( const ByteArray B)
inlineexplicit

Constructs an IsoString with a copy of the bytes stored in the specified ByteArray object.

Source unsigned 8-bit integers will be reinterpreted as signed 8-bit characters.

Definition at line 5614 of file String.h.

◆ IsoString() [15/29]

pcl::IsoString::IsoString ( bool  x)
inlineexplicit

Constructs an IsoString as a literal representation of a bool value.

Definition at line 5623 of file String.h.

◆ IsoString() [16/29]

pcl::IsoString::IsoString ( short  x)
inlineexplicit

Constructs an IsoString as a literal representation of a signed short value.

Definition at line 5632 of file String.h.

◆ IsoString() [17/29]

pcl::IsoString::IsoString ( unsigned short  x)
inlineexplicit

Constructs an IsoString as a literal representation of an unsigned short value.

Definition at line 5642 of file String.h.

◆ IsoString() [18/29]

pcl::IsoString::IsoString ( int  x)
inlineexplicit

Constructs an IsoString as a literal representation of a signed int value.

Definition at line 5652 of file String.h.

◆ IsoString() [19/29]

pcl::IsoString::IsoString ( unsigned int  x)
inlineexplicit

Constructs an IsoString as a literal representation of an unsigned int value.

Definition at line 5662 of file String.h.

◆ IsoString() [20/29]

pcl::IsoString::IsoString ( long  x)
inlineexplicit

Constructs an IsoString as a literal representation of a signed long value.

Definition at line 5672 of file String.h.

◆ IsoString() [21/29]

pcl::IsoString::IsoString ( unsigned long  x)
inlineexplicit

Constructs an IsoString as a literal representation of an unsigned long value.

Definition at line 5682 of file String.h.

◆ IsoString() [22/29]

pcl::IsoString::IsoString ( long long  x)
inlineexplicit

Constructs an IsoString as a literal representation of a signed long long value.

Definition at line 5692 of file String.h.

◆ IsoString() [23/29]

pcl::IsoString::IsoString ( unsigned long long  x)
inlineexplicit

Constructs an IsoString as a literal representation of an unsigned long long value.

Definition at line 5702 of file String.h.

◆ IsoString() [24/29]

pcl::IsoString::IsoString ( float  x)
inlineexplicit

Constructs an IsoString as a literal representation of a float value.

Definition at line 5712 of file String.h.

◆ IsoString() [25/29]

pcl::IsoString::IsoString ( double  x)
inlineexplicit

Constructs an IsoString as a literal representation of a double value.

Definition at line 5722 of file String.h.

◆ IsoString() [26/29]

pcl::IsoString::IsoString ( long double  x)
inlineexplicit

Constructs an IsoString as a literal representation of a long double value.

Definition at line 5732 of file String.h.

◆ IsoString() [27/29]

pcl::IsoString::IsoString ( Complex< float > &  x)
inlineexplicit

Constructs an IsoString as a literal representation of an fcomplex value.

Definition at line 5748 of file String.h.

References pcl::Complex< T >::Imag(), and pcl::Complex< T >::Real().

◆ IsoString() [28/29]

pcl::IsoString::IsoString ( Complex< double > &  x)
inlineexplicit

Constructs an IsoString as a literal representation of a dcomplex value.

Definition at line 5758 of file String.h.

References pcl::Complex< T >::Imag(), and pcl::Complex< T >::Real().

◆ IsoString() [29/29]

pcl::IsoString::IsoString ( Complex< long double > &  x)
inlineexplicit

Constructs an IsoString as a literal representation of an lcomplex value.

Definition at line 5768 of file String.h.

References pcl::Complex< T >::Imag(), and pcl::Complex< T >::Real().

Member Function Documentation

◆ AppendFormat()

IsoString& pcl::IsoString::AppendFormat ( const_c_string  fmt,
  ... 
)
inline

Appends a formatted representation of a variable-length set of values to the current contents of this string. Returns a reference to this string.

The fmt null-terminated string is a standard printf format string. It follows the same rules as its counterpart parameter in the standard printf( const char* fmt, ... ) C runtime function.

The required space to store the resulting formatted output is calculated and allocated transparently.

Definition at line 6544 of file String.h.

◆ AppendVFormat()

int pcl::IsoString::AppendVFormat ( const_c_string  fmt,
va_list  paramList 
)

Appends a formatted representation of a variable-length set of values, specified as a va_list standard parameter list, to the current contents of this string. Returns the number of characters appended.

The fmt null-terminated string is a standard printf format string. It follows the same rules as its counterpart parameter in the standard printf( const char* fmt, ... ) C runtime function.

The required space to store the resulting formatted output is calculated and allocated transparently.

◆ CurrentLocalISO8601DateTime()

static IsoString pcl::IsoString::CurrentLocalISO8601DateTime ( const ISO8601ConversionOptions options = ISO8601ConversionOptions())
static

Returns an ASCII representation of the current local date and time in ISO 8601 extended format.

Parameters
optionsOptional settings to control the representation of date and time in ISO 8601 format.
See also
CurrentUTCISO8601DateTime(), ToISO8601DateTime(), ISO8601ConversionOptions

◆ CurrentUTCISO8601DateTime()

static IsoString pcl::IsoString::CurrentUTCISO8601DateTime ( const ISO8601ConversionOptions options = ISO8601ConversionOptions())
static

Returns an ASCII representation of the current UTC date and time in ISO 8601 extended format.

Parameters
optionsOptional settings to control the representation of date and time in ISO 8601 format.
See also
CurrentLocalISO8601DateTime(), ToISO8601DateTime(), ISO8601ConversionOptions, TimePoint::Now()

◆ DecodedHTMLSpecialChars()

IsoString pcl::IsoString::DecodedHTMLSpecialChars ( ) const
inline

Returns a duplicate of this string with all occurrences of special HTML entities replaced with their corresponding plain text character equivalents.

See also
ToDecodedHTMLSpecialChars(), EncodedHTMLSpecialChars()

Definition at line 6338 of file String.h.

◆ EncodedHTMLSpecialChars()

IsoString pcl::IsoString::EncodedHTMLSpecialChars ( ) const
inline

Returns a duplicate of this string with all occurrences of HTML special characters replaced with valid HTML entities.

See also
ToEncodedHTMLSpecialChars(), DecodedHTMLSpecialChars()

Definition at line 6308 of file String.h.

◆ Format()

IsoString& pcl::IsoString::Format ( const_c_string  fmt,
  ... 
)
inline

Replaces the contents of this string with a formatted representation of a variable-length set of values. Returns a reference to this string.

The fmt null-terminated string is a standard printf format string. It follows the same rules as its counterpart parameter in the standard printf( const char* fmt, ... ) C runtime function.

The required space to store the resulting formatted output is calculated and allocated transparently.

Definition at line 6522 of file String.h.

Referenced by pcl::RGBAColorToHexString(), and pcl::RGBColorToHexString().

◆ FromBase64()

ByteArray pcl::IsoString::FromBase64 ( ) const

Decodes a Base64-encoded string, and returns the decoded binary raw data stored in a ByteArray object.

This function expects this string to be Base64-encoded; if it isn't, or if it contains an invalid Base64 representation, a ParseError exception will be thrown.

If this string is empty, this function returns an empty ByteArray.

See also
ToBase64(), FromHex()

◆ FromHex()

ByteArray pcl::IsoString::FromHex ( ) const

Decodes an hex-encoded string, and returns the decoded binary raw data stored in a ByteArray object.

This function expects this string to be hex-encoded; if it isn't, or if it contains invalid hexadecimal digits, a ParseError exception will be thrown.

If this string is empty, this function returns an empty ByteArray.

See also
ToHex(), FromBase64()

◆ FromURLEncoded() [1/3]

static ByteArray pcl::IsoString::FromURLEncoded ( const void *  data,
size_type  length 
)
static

Decodes a URL-encoded string stored as a raw data vector of the specified length in bytes. Returns the decoded binary raw data as a ByteArray object.

This function replaces all percent-encoded character representations in the specified data vector with their actual characters in the output array.

See also
FromURLEncoded(), ToURLEncoded( const void*, size_type )

◆ FromURLEncoded() [2/3]

template<class C >
static ByteArray pcl::IsoString::FromURLEncoded ( const C &  c)
inlinestatic

Decodes a URL-encoded generic string represented as a container c. Returns the decoded binary raw data as a ByteArray object.

See also
FromURLEncoded( const void*, size_type ), ToURLEncoded( const void*, size_type )

Definition at line 6417 of file String.h.

◆ FromURLEncoded() [3/3]

ByteArray pcl::IsoString::FromURLEncoded ( ) const
inline

Decodes this URL-encoded string, and returns the decoded binary raw data as a ByteArray object.

This function replaces all percent-encoded character representations in this string with their actual characters in the output array.

If this string is empty, this function returns an empty ByteArray.

See also
FromURLEncoded( const void*, size_type ), ToURLEncoded()

Definition at line 6433 of file String.h.

◆ MBSToWCS()

ustring_base pcl::IsoString::MBSToWCS ( ) const

Returns a copy of this multibyte string converted to a UTF-16 string. This conversion is dependent on the current locale.

In the event of conversion error (if there are invalid multibyte characters in the source string) this routine returns an empty string.

This member function is a convenience wrapper for the mbstowcs() routine of the standard C runtime library. Note that on platforms where the size of wchar_t is four bytes (e.g. Linux) this routine performs an additional conversion from UTF-32 to UTF-16. On platforms where the size of wchar_t is two bytes (e.g. Windows), the conversion is direct.

See also
UTF8ToUTF16(), ToString()

◆ operator=() [1/8]

IsoString& pcl::IsoString::operator= ( const IsoString s)
inline

Copy assignment operator. Returns a reference to this object.

Definition at line 5812 of file String.h.

◆ operator=() [2/8]

IsoString& pcl::IsoString::operator= ( IsoString &&  s)
inline

Move assignment operator. Returns a reference to this object.

Definition at line 5821 of file String.h.

◆ operator=() [3/8]

IsoString& pcl::IsoString::operator= ( const string_base s)
inline

Assigns a shallow copy of the string_base string s to this string. Returns a reference to this object.

Definition at line 5831 of file String.h.

◆ operator=() [4/8]

IsoString& pcl::IsoString::operator= ( string_base &&  s)
inline

Transfers the data from the string_base string s to this string (move assignment from base class). Returns a reference to this object.

Definition at line 5841 of file String.h.

◆ operator=() [5/8]

IsoString& pcl::IsoString::operator= ( const ustring_base s)
inline

Assigns a copy of the Unicode string s (UTF-16) to this string, after converting source UTF-16 characters to ISO/IEC-8859-1 characters. Returns a reference to this object.

If the specified UTF-16 string contains characters that cannot be converted to ISO/IEC-8859-1, the corresponding characters in this string will have undefined values. For conversions from UTF-16 to UTF-8, see String::ToUTF8() and String::UTF16ToUTF8().

Definition at line 5857 of file String.h.

References pcl::GenericString< T, R, A >::Begin().

◆ operator=() [6/8]

IsoString& pcl::IsoString::operator= ( const_c_string  t)
inline

Assigns a copy of the null-terminated string t to this string. Returns a reference to this object.

Definition at line 5866 of file String.h.

◆ operator=() [7/8]

IsoString& pcl::IsoString::operator= ( char_type  c)
inline

Assigns a single copy of a character c to this string. Returns a reference to this object.

Definition at line 5876 of file String.h.

◆ operator=() [8/8]

IsoString & pcl::IsoString::operator= ( const_c_ustring  t)
inline

Assigns a copy of the null-terminated Unicode string s (UTF-16) to this string, after converting source UTF-16 characters to ISO/IEC-8859-1 characters. Returns a reference to this object.

If the specified UTF-16 string contains characters that cannot be converted to ISO/IEC-8859-1, the corresponding characters in this string will have undefined values. For conversions from UTF-16 to UTF-8, see String::ToUTF8() and String::UTF16ToUTF8().

Definition at line 12003 of file String.h.

References pcl::GenericString< char, IsoCharTraits, StandardAllocator >::Clear(), pcl::GenericString< char, IsoCharTraits, StandardAllocator >::end(), and pcl::CharTraits::Length().

◆ ParseISO8601DateTime()

void pcl::IsoString::ParseISO8601DateTime ( int &  year,
int &  month,
int &  day,
double &  dayf,
double &  tz 
) const

Evaluates this string as a date and time specification in ISO 8601 extended format, and stores the resulting components in the specified variables.

Parameters
yearOn output, the year of the date.
monthOn output, the month of the date in the range [1,12].
dayOn output, the day of the date in the range [1,31].
dayfOn output, the day fraction corresponding to the time specification, in the range [0,1).
tzOn output, the time zone offset in hours, in the range [-12,+12].

In ISO 8601 extended representations, decimal fractions must be divided from integer parts exclusively by the full stop or dot character ('.', ASCII code point 46(10) = 2E(16)).

See also
TryParseISO8601DateTime(), TimePoint::FromString()

Referenced by pcl::TimePoint::FromString(), and pcl::TimePoint::TimePoint().

◆ Random()

static IsoString pcl::IsoString::Random ( size_type  n,
RandomizationOptions  options = RandomizationOption::Default 
)
static

Generates a string of n random 8-bit code points, with character types and ranges as prescribed by the specified options.

See also
RandomizationOption

◆ ToBase64() [1/2]

static IsoString pcl::IsoString::ToBase64 ( const void *  data,
size_type  length 
)
static

Returns a Base64-encoded string for a binary data block of the specified length in bytes.

Base64 is a MIME content transfer encoding of binary data translated into a base 64 representation composed of printable characters. See RFC 1421 (http://tools.ietf.org/html/rfc1421).

See also
ToBase64( const C& ), ToHex(), ToByteArray()

◆ ToBase64() [2/2]

template<class C >
static IsoString pcl::IsoString::ToBase64 ( const C &  c)
inlinestatic

Returns a Base64-encoded string for a container c, whose contents are treated as raw binary data. The objects stored in the container are considered as a sequence of bytes, irrespective of their actual data types or the classes they are instances of.

The type C represents an array of contiguous objects, and must provide PCL container semantics: the Begin() and Length() standard container functions are required.

See also
ToBase64( const void*, size_type ), ToByteArray()

Definition at line 7508 of file String.h.

◆ ToBool()

bool pcl::IsoString::ToBool ( ) const

Evaluates this string as a Boolean literal, and returns the result as a bool value.

Returns true if this string is equal to "1", "true", "TRUE" or "T". Returns false if this string is equal to "0", "false", "FALSE" or "F". Otherwise this function throws a ParseError exception.

See also
TryToBool()

◆ ToByteArray()

ByteArray pcl::IsoString::ToByteArray ( ) const
inline

Returns a ByteArray object that stores a copy of this string. In the returned array, source 8-bit characters have been reinterpreted as unsigned 8-bit integers.

See also
ToBase64(), ToHex()

Definition at line 7520 of file String.h.

◆ ToColonSeparated()

template<class C >
IsoString& pcl::IsoString::ToColonSeparated ( const C &  c)
inline

Replaces the contents of this string with a sequence of colon-separated tokens extracted from a container c. Returns a reference to this string.

This member function is equivalent to:

ToSeparated( c, ':' );

Definition at line 6205 of file String.h.

◆ ToCommaSeparated()

template<class C >
IsoString& pcl::IsoString::ToCommaSeparated ( const C &  c)
inline

Replaces the contents of this string with a sequence of comma-separated tokens extracted from a container c. Returns a reference to this string.

This member function is equivalent to:

ToSeparated( c, ',' );

Definition at line 6190 of file String.h.

◆ ToDecodedHTMLSpecialChars()

IsoString& pcl::IsoString::ToDecodedHTMLSpecialChars ( )

Replaces all occurrences of special HTML entities in this string with their corresponding plain text character equivalents. Returns a reference to this string.

The following replacements are performed:

"\&amp;" (ampersand) becomes '&'
"\&quot;" (double quote) becomes '"'
"\&#039;" (single quote) becomes "'"
"\&apos;" (apostrophe) becomes "'"
"\&lt;" (less than) becomes '<'
"\&gt;" (greater than) becomes '>'

See also
DecodedHTMLSpecialChars(), ToEncodedHTMLSpecialChars()

◆ ToDouble()

double pcl::IsoString::ToDouble ( ) const

Evaluates this string as a floating point literal, and returns the result as a double value.

The source string is expected to have the following format (informal format specification):

[+|-][<integer-part>][.[<decimal-part>]][<exp>[+|-]<exponent>]

where <integer-part> and <decimal-part> are optional sequences of decimal digits from 0 to 9, <exp> is an exponent specifier (the letter 'e' (or 'E')), and <exponent> is a sequence of decimal digits specifying a power of ten that multiplies the preceding numeric constant. At least a one-digit integer part, or a one-digit decimal part, is mandatory. FORTRAN exponent specifiers ('d' and 'f' (or 'D' and 'F')) are also recognized by this implementation.

If this string doesn't contain a valid floating point literal, or if the range of double is exceeded, this member function throws a ParseError exception.

See also
TryToDouble()

◆ ToEncodedHTMLSpecialChars()

IsoString& pcl::IsoString::ToEncodedHTMLSpecialChars ( )

Replaces all occurrences of HTML special characters in this string with valid HTML entities. Returns a reference to this string.

The following replacements are performed:

'&' (ampersand) becomes "\&amp;"
'"' (double quote) becomes "\&quot;"
"'" (single quote) becomes "\&#039;"
'<' (less than) becomes "\&lt;"
'>' (greater than) becomes "\&gt;"

See also
EncodedHTMLSpecialChars(), ToDecodedHTMLSpecialChars()

◆ ToFloat()

float pcl::IsoString::ToFloat ( ) const

Evaluates this string as a floating point numeric literal, and returns the result as a float value.

For information about the legal syntax of a floating point literal, see the documentation for the ToDouble() member function.

If this string doesn't contain a valid floating point literal, or if the range of float is exceeded, this member function throws a ParseError exception.

See also
TryToFloat()

◆ ToHex() [1/2]

static IsoString pcl::IsoString::ToHex ( const void *  data,
size_type  length 
)
static

Returns an hex-encoded string for a binary data block of the specified length in bytes. The hex-encoded string is composed of hexadecimal digits: 0-9 and a-f, and its length is twice that of the input length.

See also
ToHex( const C& ), ToBase64(), ToByteArray()

Referenced by pcl::AES256::AES256().

◆ ToHex() [2/2]

template<class C >
static IsoString pcl::IsoString::ToHex ( const C &  c)
inlinestatic

Returns an hex-encoded string for a container c, whose contents are treated as raw binary data. The objects stored in the container are considered as a sequence of bytes, irrespective of their actual data types or the classes they are instances of.

The type C represents an array of contiguous objects, and must provide PCL container semantics: the Begin() and Length() standard container functions are required.

See also
ToHex( const void*, size_type )

Definition at line 7478 of file String.h.

◆ ToHyphenated()

template<class C >
IsoString& pcl::IsoString::ToHyphenated ( const C &  c)
inline

Replaces the contents of this string with a hyphenated sequence of tokens extracted from a container c. Returns a reference to this string.

This member function is equivalent to:

ToSeparated( c, '-' );

Definition at line 6279 of file String.h.

◆ ToInt() [1/2]

long pcl::IsoString::ToInt ( ) const
inline

Evaluates this string as an integer literal, and returns the result as a long value.

Calling this member function for a string s is equivalent to:

long n = s.ToInt( 0 );

See the documentation under ToInt( int ) for information about automatic base conversions when base=0 is specified.

If this string doesn't contain a valid integer literal, or if the range of long is exceeded, this member function throws a ParseError exception.

See also
TryToInt()

Definition at line 6771 of file String.h.

◆ ToInt() [2/2]

long pcl::IsoString::ToInt ( int  base) const

Evaluates this string as an integer literal in the specified base, and returns the result as a long value.

If base is 0, the source string is expected to represent either a decimal constant, an octal constant, or a hexadecimal constant, any of which optionally preceded by a sign character (+ or -). A decimal constant begins with a non-zero digit, and consists of a sequence of decimal digits from '0' to '9'. An octal begins with the prefix '0', optionally followed by a sequence of the digits 0 to 7 only. A hexadecimal constant begins with the prefix '0x' or '0X', which must be followed by a sequence of decimal digits and letters from 'a' (or 'A') to 'f' (or 'F'), whose corresponding decimal values are from 10 to 15, respectively.

Other legal values of base, from 2 to 36, specify the expected base of the integer constant represented by the source string. Decimal digits and letters from 'a' (or 'A') to 'z' (or 'Z') are used to represent all possible digits in the specified base, as necessary.

If this string doesn't contain a valid integer literal in the specified base, if an illegal base is specified, or if the range of long is exceeded, this member function throws a ParseError exception.

See also
TryToInt( int&, int ) const

◆ ToInt64() [1/2]

long long pcl::IsoString::ToInt64 ( ) const
inline

Evaluates this string as an integer literal, and returns the result as a long long value.

Calling this member function for a string s is equivalent to:

long long n = s.ToInt64( 0 );

If this string doesn't contain a valid integer literal, or if the range of long long is exceeded, this member function throws a ParseError exception.

See also
TryToInt64()

Definition at line 6952 of file String.h.

◆ ToInt64() [2/2]

long long pcl::IsoString::ToInt64 ( int  base) const

Evaluates this string as an unsigned integer literal in the specified base, and returns the result as a long long value.

For information about possible values of base and how these are interpreted, see the documentation under ToInt( int ).

If this string doesn't contain a valid integer literal in the specified base, if an illegal base is specified, or if the range of long long is exceeded, this member function throws a ParseError exception.

See also
TryToInt64( long long&, int ) const

◆ ToISO8601DateTime()

static IsoString pcl::IsoString::ToISO8601DateTime ( int  year,
int  month,
int  day,
double  dayf,
double  tz = 0,
const ISO8601ConversionOptions options = ISO8601ConversionOptions() 
)
static

Returns an ASCII representation of a date and time in ISO 8601 extended format.

Parameters
yearThe year of the date.
monthThe month of the date in the range [1,12].
dayThe day of the date in the range [1,31].
dayfThe day fraction corresponding to the time specification, in the range [0,1).
tzThe time zone offset in hours, in the range [-12,+12]. The default value is zero, to be interpreted as UTC.
optionsOptional settings to control the representation of date and time in ISO 8601 format.
See also
CurrentUTCISO8601DateTime(), CurrentLocalISO8601DateTime(), ParseISO8601DateTime(), ISO8601ConversionOptions, TimePoint::ToIsoString()

◆ ToNewLineSeparated()

template<class C >
IsoString& pcl::IsoString::ToNewLineSeparated ( const C &  c)
inline

Replaces the contents of this string with a sequence of new line separated tokens extracted from a container c. Returns a reference to this string.

This member function is equivalent to:

ToSeparated( c, '\n' );

Definition at line 6250 of file String.h.

◆ ToNullSeparated()

template<class C >
IsoString& pcl::IsoString::ToNullSeparated ( const C &  c)
inline

Replaces the contents of this string with a sequence of null-separated tokens extracted from a container c. Returns a reference to this string.

This member function is equivalent to:

ToSeparated( c, '\0' );

Definition at line 6265 of file String.h.

◆ ToSeparated() [1/6]

template<class C >
IsoString& pcl::IsoString::ToSeparated ( const C &  c,
char_type  separator 
)
inline

Replaces the contents of this string with a sequence of tokens extracted from a container c, separated with the specified separator character. Returns a reference to this string.

The container type C must have separated list generation semantics. All iterable PCL containers such as Array, Vector, etc. provide the necessary ToSeparated member functions.

Definition at line 6075 of file String.h.

◆ ToSeparated() [2/6]

template<class C , class AF >
IsoString& pcl::IsoString::ToSeparated ( const C &  c,
char_type  separator,
AF  append 
)
inline

Replaces the contents of this string with a sequence of tokens extracted from a container c, separated with the specified separator character, and built using an append binary function. Returns a reference to this string.

The binary function must be of the form:

void append( IsoString& s, char c );

where c is being appended to s.

The container type C must have separated list generation semantics. All iterable PCL containers such as Array, Vector, etc. provide the necessary ToSeparated member functions.

Definition at line 6098 of file String.h.

◆ ToSeparated() [3/6]

template<class C >
IsoString& pcl::IsoString::ToSeparated ( const C &  c,
const IsoString separator 
)
inline

Replaces the contents of this string with a sequence of tokens extracted from a container c, separated with the specified separator string. Returns a reference to this string.

The container type C must have separated list generation semantics. All iterable PCL containers such as Array, Vector, etc. provide the necessary ToSeparated member functions.

Definition at line 6114 of file String.h.

◆ ToSeparated() [4/6]

template<class C , class AF >
IsoString& pcl::IsoString::ToSeparated ( const C &  c,
const IsoString separator,
AF  append 
)
inline

Replaces the contents of this string with a sequence of tokens extracted from a container c, separated with the specified separator string, and built using an append binary function. Returns a reference to this string.

The binary function must be of the form:

void append( IsoString& s1, const IsoString& s2 );

where s2 is being appended to s1.

The container type C must have separated list generation semantics. All iterable PCL containers such as Array, Vector, etc. provide the necessary ToSeparated member functions.

Definition at line 6137 of file String.h.

◆ ToSeparated() [5/6]

template<class C >
IsoString& pcl::IsoString::ToSeparated ( const C &  c,
const_c_string  separator 
)
inline

Replaces the contents of this string with a sequence of tokens extracted from a container c, separated with the specified separator null-terminated string. Returns a reference to this string.

The container type C must have separated list generation semantics. All iterable PCL containers such as Array, Vector, etc. provide the necessary ToSeparated member functions.

Definition at line 6153 of file String.h.

◆ ToSeparated() [6/6]

template<class C , class AF >
IsoString& pcl::IsoString::ToSeparated ( const C &  c,
const_c_string  separator,
AF  append 
)
inline

Replaces the contents of this string with a sequence of tokens extracted from a container c, separated with the specified separator null-terminated string, and built using an append binary function. Returns a reference to this string.

The binary function must be of the form:

void append( IsoString& s1, const char* s2 );

where s2 is being appended to s1.

The container type C must have separated list generation semantics. All iterable PCL containers such as Array, Vector, etc. provide the necessary ToSeparated member functions.

Definition at line 6175 of file String.h.

◆ ToSpaceSeparated()

template<class C >
IsoString& pcl::IsoString::ToSpaceSeparated ( const C &  c)
inline

Replaces the contents of this string with a sequence of space-separated tokens extracted from a container c. Returns a reference to this string.

This member function is equivalent to:

ToSeparated( c, ' ' );

Definition at line 6220 of file String.h.

◆ ToString()

ustring_base pcl::IsoString::ToString ( ) const
inline

Returns a UTF-16 string with a converted copy of this IsoString object.

This function assumes that this IsoString object contains only valid ISO/IEC-8859-1 characters. To perform UTF-8 to UTF-16 conversions, see UTF8ToUTF16() and MBSToWCS().

See also
UTF8ToUTF16(), MBSToWCS()

Definition at line 6594 of file String.h.

References pcl::GenericString< T, R, A >::Begin(), and pcl::GenericString< T, R, A >::SetLength().

◆ ToTabSeparated()

template<class C >
IsoString& pcl::IsoString::ToTabSeparated ( const C &  c)
inline

Replaces the contents of this string with a sequence of tabulator-separated tokens extracted from a container c. Returns a reference to this string.

This member function is equivalent to:

ToSeparated( c, '\t' );

Definition at line 6235 of file String.h.

◆ ToUInt() [1/2]

unsigned long pcl::IsoString::ToUInt ( ) const
inline

Evaluates this string as an unsigned integer literal, and returns the result as an unsigned long value.

Calling this member function for a string s is equivalent to:

unsigned long n = s.ToUInt( 0 );

See the documentation under ToInt( int ) for information about automatic base conversions when base=0 is specified.

If this string doesn't contain a valid unsigned integer literal, or if the range of unsigned long is exceeded, this member function throws a ParseError exception.

See also
TryToUInt()

Definition at line 6868 of file String.h.

◆ ToUInt() [2/2]

unsigned long pcl::IsoString::ToUInt ( int  base) const

Evaluates this string as an unsigned integer literal in the specified base, and returns the result as an unsigned long value.

For information about possible values of base and how these are interpreted, see the documentation under ToInt( int ). The only exception is that for this member function, only a + sign is legal preceding the numeric constant represented by the source string.

If this string doesn't contain a valid integer literal in the specified base, if an illegal base is specified, or if the range of unsigned long is exceeded, this member function throws a ParseError exception.

See also
TryToUInt( unsigned&, int ) const

◆ ToUInt64() [1/2]

unsigned long long pcl::IsoString::ToUInt64 ( ) const
inline

Evaluates this string as an unsigned integer literal in the specified base, and returns the result as an unsigned long long value.

Calling this member function for a string s is equivalent to:

unsigned long long n = s.ToUInt64( 0 );

If this string doesn't contain a valid unsigned integer literal, or if the range of unsigned long long is exceeded, this member function throws a ParseError exception.

See also
TryToUInt64()

Definition at line 7035 of file String.h.

◆ ToUInt64() [2/2]

unsigned long long pcl::IsoString::ToUInt64 ( int  base) const

Evaluates this string as an unsigned integer literal in the specified base, and returns the result as an unsigned long long value.

For information about possible values of base and how these are interpreted, see the documentation under ToInt( int ).

If this string doesn't contain a valid unsigned integer literal in the specified base, if an illegal base is specified, or if the range of unsigned long long is exceeded, this member function throws a ParseError exception.

See also
TryToUInt64( unsigned long long&, int ) const

◆ ToURLDecoded() [1/3]

static IsoString pcl::IsoString::ToURLDecoded ( const void *  data,
size_type  length 
)
static

Decodes a URL-encoded string stored as a raw data vector of the specified length in bytes. Returns the decoded data stored as an 8-bit string.

This function replaces all percent-encoded character representations in the specified data vector with their actual characters in the output string.

See also
ToURLDecoded(), URLDecoded()

◆ ToURLDecoded() [2/3]

template<class C >
static IsoString pcl::IsoString::ToURLDecoded ( const C &  c)
inlinestatic

Decodes a URL-encoded generic string represented as a container c. Returns the decoded data stored as an 8-bit string.

See also
ToURLDecoded( const void*, size_type ), ToURLDecoded(), URLDecoded()

Definition at line 6458 of file String.h.

◆ ToURLDecoded() [3/3]

IsoString& pcl::IsoString::ToURLDecoded ( )

Replaces all percent-encoded representations of characters with their actual characters. Returns a reference to this string.

This is the reverse transformation to URL encoding. See ToURLEncoded() for more information.

See also
URLDecoded(), ToURLEncoded(), FromURLEncoded()

◆ ToURLEncoded() [1/3]

static IsoString pcl::IsoString::ToURLEncoded ( const void *  data,
size_type  length 
)
static

Returns a URL-encoded string that represents a binary data block of the specified length in bytes.

In a URL-encoded string, all characters that are not a-z, A-Z, 0-9, '-', '.', '_' or '~' are replaced with their percent-encoded representation NN, where NN is a zero-padded, two-digit uppercase hexadecimal number. See RFC 3986 (http://tools.ietf.org/html/rfc3986).

See also
ToURLEncoded( const C& ), ToURLEncoded()

◆ ToURLEncoded() [2/3]

template<class C >
static IsoString pcl::IsoString::ToURLEncoded ( const C &  c)
inlinestatic

Returns a URL-encoded string for a container c, whose contents are treated as raw binary data. The objects stored in the container are considered as a sequence of bytes, irrespective of their actual data types or the classes they are instances of.

The type C represents an array of contiguous objects, and must provide PCL container semantics: the Begin() and Length() standard container functions are required.

See also
ToURLEncoded( const void*, size_type )

Definition at line 6369 of file String.h.

◆ ToURLEncoded() [3/3]

IsoString& pcl::IsoString::ToURLEncoded ( )

Replaces all characters that are not a-z, A-Z, 0-9, '-', '.', '_' or '~' with their percent-encoded representation NN, where NN is a zero-padded, two-digit uppercase hexadecimal number. Returns a reference to this string. See RFC 3986 / URI Generic Syntax, for more information on URL encodings.

See also
URLEncoded(), ToURLDecoded()

◆ TryParseISO8601DateTime()

bool pcl::IsoString::TryParseISO8601DateTime ( int &  year,
int &  month,
int &  day,
double &  dayf,
double &  tz 
) const

Attempts to evaluate this string as a date and time specification in ISO 8601 extended format. If successful, stores the resulting components in the specified year, month, day and dayf and tz variables, and returns true. For more information on syntax and output values and ranges, see the ParseISO8601DateTime().

If this string cannot be evaluated as a valid date and time in ISO 8601 format, this function returns false and does not change any of the passed variables. This function does not throw any exception.

See also
ParseISO8601DateTime(), TimePoint::TryFromString()

Referenced by pcl::TimePoint::TryFromString().

◆ TryToBool()

bool pcl::IsoString::TryToBool ( bool &  value) const

Attempts to evaluate this string as a Boolean literal.

If this string can legally be converted to a Boolean value, this function returns true and stores the evaluation result in the value variable. A string can only be converted to Boolean type if it is equal to either "1", "true", "TRUE", "T", "0", "false", "FALSE" or "F".

If this string cannot be converted to a Boolean value, this function returns false and does not change the value variable. This function does not throw any exception.

See also
ToBool()

◆ TryToDouble()

bool pcl::IsoString::TryToDouble ( double &  value) const

Attempts to evaluate this string as a floating point numeric literal.

If this string can legally be converted to a floating point number, this function returns true and stores the evaluation result in the value variable. For information about the legal syntax of a floating point literal, see the documentation for the ToDouble() member function.

If this string cannot be converted to a floating point number, this function returns false and does not change the value variable. This function does not throw any exception.

See also
ToDouble()

Referenced by pcl::FITSHeaderKeyword::FixValueDelimiters(), and pcl::FITSHeaderKeyword::GetNumericValue().

◆ TryToFloat()

bool pcl::IsoString::TryToFloat ( float &  value) const

Attempts to evaluate this string as a floating point numeric literal.

If this string can legally be converted to a floating point number, this function returns true and stores the evaluation result in the value variable. For information about the legal syntax of a floating point literal, see the documentation for the ToDouble() member function.

If this string cannot be converted to a floating point number, this function returns false and does not change the value variable. This function does not throw any exception.

See also
ToFloat()

◆ TryToInt() [1/2]

bool pcl::IsoString::TryToInt ( int &  value) const
inline

Attempts to evaluate this string as an integer numeric literal.

If this string can legally be converted to an integer number, this function returns true and stores the evaluation result in the value variable.

Calling this member function for a string s is equivalent to:

int v;
if ( s.TryToInt( v, 0 ) ) ...

See the documentation under ToInt( int ) for information about automatic base conversions when base=0 is specified.

If this string cannot be converted to an integer number, this function returns false and does not change the value variable. This function does not throw any exception.

See also
ToInt()

Definition at line 6799 of file String.h.

◆ TryToInt() [2/2]

bool pcl::IsoString::TryToInt ( int &  value,
int  base 
) const

Attempts to evaluate this string as an integer numeric literal in the specified base.

If this string can legally be converted to an integer number in the specified base, this function returns true and stores the evaluation result in the value variable.

See the documentation under ToInt( int ) for information about automatic base conversions when base=0 is specified.

If this string cannot be converted to an integer number in the specified base, this function returns false and does not change the value variable. This function does not throw any exception.

See also
ToInt( int ) const

◆ TryToInt64() [1/2]

bool pcl::IsoString::TryToInt64 ( long long &  value) const
inline

Attempts to evaluate this string as a 64-bit integer numeric literal in the specified base.

If this string can legally be converted to a 64-bit integer number in the specified base, this function returns true and stores the evaluation result in the value variable.

Calling this member function for a string s is equivalent to:

long long v;
if ( s.TryToInt64( v, 0 ) ) ...

See the documentation under ToInt( int ) for information about automatic base conversions when base=0 is specified.

If this string cannot be converted to a 64-bit integer number, this function returns false and does not change the value variable. This function does not throw any exception.

See also
ToInt64()

Definition at line 6981 of file String.h.

◆ TryToInt64() [2/2]

bool pcl::IsoString::TryToInt64 ( long long &  value,
int  base 
) const

Attempts to evaluate this string as a 64-bit integer numeric literal in the specified base.

If this string can legally be converted to a 64-bit integer number in the specified base, this function returns true and stores the evaluation result in the value variable.

For information about possible values of base and how these are interpreted, see the documentation under ToInt( int ).

If this string cannot be converted to a 64-bit integer number in the specified base, this function returns false and does not change the value variable. This function does not throw any exception.

See also
ToInt64( int ) const

◆ TryToUInt() [1/2]

bool pcl::IsoString::TryToUInt ( unsigned &  value) const
inline

Attempts to evaluate this string as an unsigned integer literal.

If this string can legally be converted to an unsigned integer number, this function returns true and stores the evaluation result in the value variable.

Calling this member function for a string s is equivalent to:

unsigned v;
if ( s.TryToUInt( v, 0 ) ) ...

See the documentation under ToInt( int ) for information about automatic base conversions when base=0 is specified.

If this string cannot be converted to an integer number, this function returns false and does not change the value variable. This function does not throw any exception.

See also
ToUInt()

Definition at line 6896 of file String.h.

◆ TryToUInt() [2/2]

bool pcl::IsoString::TryToUInt ( unsigned &  value,
int  base 
) const

Attempts to evaluate this string as an unsigned integer literal in the specified base.

If this string can legally be converted to an unsigned integer number in the specified base, this function returns true and stores the evaluation result in the value variable.

See the documentation under ToUInt( int ) for information about automatic base conversions when base=0 is specified.

If this string cannot be converted to an unsigned integer number in the specified base, this function returns false and does not change the value variable. This function does not throw any exception.

See also
ToUInt( int ) const

◆ TryToUInt64() [1/2]

bool pcl::IsoString::TryToUInt64 ( unsigned long long &  value) const
inline

Attempts to evaluate this string as a 64-bit unsigned integer numeric literal in the specified base.

If this string can legally be converted to a 64-bit unsigned integer number in the specified base, this function returns true and stores the evaluation result in the value variable.

Calling this member function for a string s is equivalent to:

unsigned long long v;
if ( s.TryToUInt64( v, 0 ) ) ...

See the documentation under ToInt( int ) for information about automatic base conversions when base=0 is specified.

If this string cannot be converted to a 64-bit unsigned integer number, this function returns false and does not change the value variable. This function does not throw any exception.

See also
ToUInt64()

Definition at line 7064 of file String.h.

◆ TryToUInt64() [2/2]

bool pcl::IsoString::TryToUInt64 ( unsigned long long &  value,
int  base 
) const

Attempts to evaluate this string as an unsigned 64-bit integer numeric literal in the specified base.

If this string can legally be converted to an unsigned 64-bit integer number in the specified base, this function returns true and stores the evaluation result in the value variable.

For information about possible values of base and how these are interpreted, see the documentation under ToInt( int ).

If this string cannot be converted to an unsigned 64-bit integer number in the specified base, this function returns false and does not change the value variable. This function does not throw any exception.

See also
ToUInt64( int ) const

◆ URLDecoded()

IsoString pcl::IsoString::URLDecoded ( ) const
inline

Returns a URL-decoded duplicate of this string. See ToURLDecoded() for detailed information.

See also
ToURLDecoded(), URLEncoded()

Definition at line 6480 of file String.h.

◆ URLEncoded()

IsoString pcl::IsoString::URLEncoded ( ) const
inline

Returns a URL-encoded duplicate of this string. See ToURLEncoded() for detailed information.

See also
ToURLEncoded(), URLDecoded()

Definition at line 6391 of file String.h.

◆ UTF8ToUTF16()

IsoString::ustring_base pcl::IsoString::UTF8ToUTF16 ( size_type  i = 0,
size_type  n = maxPos 
) const
inline

Returns a UTF-16 string with a representation of a subset of n contiguous UTF-8 characters from this IsoString object, starting at the i-th character.

See also
ToString(), MBSToWCS()

Definition at line 12018 of file String.h.

References pcl::GenericString< T, R, A >::Append(), pcl::GenericString< char, IsoCharTraits, StandardAllocator >::Begin(), pcl::operator+(), and pcl::String::UTF8ToUTF16().

◆ UUID()

static IsoString pcl::IsoString::UUID ( )
static

Generates a universally unique identifier (UUID) in canonical form.

The canonical UUID has 36 characters with the following format:

xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx

where 'x' represents a lowercase hexadecimal digit, '4' is the UUID version indicator (version 4 = truly random UUID), and 'y' is one of '8', '9', 'a', or 'b'.

◆ VFormat()

int pcl::IsoString::VFormat ( const_c_string  fmt,
va_list  paramList 
)

Replaces the contents of this string with a formatted representation of a variable-length set of values, specified as a va_list standard parameter list. Returns the number of characters generated.

The fmt null-terminated string is a standard printf format string. It follows the same rules as its counterpart parameter in the standard printf( const char* fmt, ... ) C runtime function.

The required space to store the resulting formatted output is calculated and allocated transparently.

Referenced by pcl::String::AppendVFormat(), and pcl::String::VFormat().


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