template<Encoding E, typename T>
struct LLU::WS::GetAs< E, T >
Utility structure used to enforce receiving given value via WSStream with encoding E.
- Template Parameters
-
| E | - desired encoding |
| T | - actual type of the expression |
This structure is only supposed to be used as a wrapper for arguments to WSStream::operator>>
- Note
- It's recommended not to use WS::GetAs constructor directly, but rather utilize a helper function WS::getAs.
WSStream<WS::Encoding::Byte> mls { mlink };
std::string stringWithNonAsciiChars;
mls << WS::getAs<WS::Encoding::UTF8>(stringWithNonAsciiChars);