Wt  4.0.2
Public Member Functions | Public Attributes | List of all members
Wt::LocalizedString Class Reference

The result of resolving a localized string. More...

Public Member Functions

 LocalizedString ()
 Constructor for an unsuccessful localized string result. More...
 
 LocalizedString (std::string v, TextFormat f)
 Constructor for a successful localized string result. More...
 
 operator bool () const
 Implicit bool conversion, for checking success.
 

Public Attributes

std::string value
 The value of the resolved localized string. More...
 
TextFormat format
 The format that the resolved localized string is stored in (TextFormat::Plain or TextFormat::XHTML)
 
bool success
 Indicates whether resolving the string was successful.
 

Detailed Description

The result of resolving a localized string.

This struct contains the result (in UTF-8 encoding) of resolving a localized string, consisting of its value, its format (TextFormat::Plain or TextFormat::XHTML), and a success value indicating whether the string was successfully resolved.

Constructor & Destructor Documentation

Wt::LocalizedString::LocalizedString ( )

Constructor for an unsuccessful localized string result.

This constructor sets success to false.

Wt::LocalizedString::LocalizedString ( std::string  v,
TextFormat  f 
)

Constructor for a successful localized string result.

Sets the value to the given string, and the format to the given format, and sets success to true.

Member Data Documentation

std::string Wt::LocalizedString::value

The value of the resolved localized string.

This value is UTF-8 encoded


Generated on Fri Nov 24 2017 for the C++ Web Toolkit (Wt) by doxygen 1.8.11