mirror of
https://github.com/shadps4-emu/ext-cryptopp.git
synced 2025-02-12 08:11:05 +00:00
Update documentation
This commit is contained in:
parent
751252b2d9
commit
a9d6604ee9
10
misc.h
10
misc.h
@ -2405,6 +2405,11 @@ struct BlockGetAndPut
|
|||||||
typedef PutBlock<T, B, PA> Put;
|
typedef PutBlock<T, B, PA> Put;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
/// \brief Convert a word to a string
|
||||||
|
/// \tparam T class or type
|
||||||
|
/// \param value the word to convert
|
||||||
|
/// \param order byte order
|
||||||
|
/// \returns a string representing the value of the word
|
||||||
template <class T>
|
template <class T>
|
||||||
std::string WordToString(T value, ByteOrder order = BIG_ENDIAN_ORDER)
|
std::string WordToString(T value, ByteOrder order = BIG_ENDIAN_ORDER)
|
||||||
{
|
{
|
||||||
@ -2414,6 +2419,11 @@ std::string WordToString(T value, ByteOrder order = BIG_ENDIAN_ORDER)
|
|||||||
return std::string((char *)&value, sizeof(value));
|
return std::string((char *)&value, sizeof(value));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// \brief Convert a string to a word
|
||||||
|
/// \tparam T class or type
|
||||||
|
/// \param str the string to convert
|
||||||
|
/// \param order byte order
|
||||||
|
/// \returns a word representing the value of the string
|
||||||
template <class T>
|
template <class T>
|
||||||
T StringToWord(const std::string &str, ByteOrder order = BIG_ENDIAN_ORDER)
|
T StringToWord(const std::string &str, ByteOrder order = BIG_ENDIAN_ORDER)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user