xtd 0.2.0
Loading...
Searching...
No Matches

◆ as< ustring >() [14/30]

template<>
ustring xtd::as< ustring > ( int16  value,
xtd::byte  from_base 
)
inline

Casts a type into another type.

Parameters
valueobject to convert.
from_baseThe base of the number in value, which must be 2, 8, 10, or 16.
Returns
A new ustring object converted from value.
Exceptions
xtd::argument_exceptionvfrom_base is not 2, 8, 10, or 16.
Header
#include <xtd/as>
Namespace
xtd
Library
xtd.core
Examples
int16 value = 42;
ustring result = as<ustring>(value, 16);
Represents text as a sequence of UTF-8 code units.
Definition ustring.h:53
int16_t int16
Represents a 16-bit signed integer.
Definition int16.h:23
ustring as< ustring >(std::any value)
Casts a type into another type.
Definition __as_ustring.h:36