30 #ifndef CEREAL_TYPES_STRING_HPP_
31 #define CEREAL_TYPES_STRING_HPP_
39 template<
class Archive,
class CharT,
class Traits,
class Alloc>
inline
40 typename std::enable_if<traits::is_output_serializable<BinaryData<CharT>, Archive>::value,
void>
::type
44 ar( make_size_tag(
static_cast<size_type>(str.size()) ) );
45 ar( binary_data( str.data(), str.size() *
sizeof(CharT) ) );
49 template<
class Archive,
class CharT,
class Traits,
class Alloc>
inline
50 typename std::enable_if<traits::is_input_serializable<BinaryData<CharT>, Archive>::value,
void>
::type
54 ar( make_size_tag( size ) );
55 str.resize(
static_cast<std::size_t
>(size));
56 ar( binary_data(
const_cast<CharT *
>( str.data() ),
static_cast<std::size_t
>(size) *
sizeof(CharT) ) );
Main cereal functionality.
type
The type the bitset is encoded with.
Definition: bitset.hpp:44
in certain simple scenarios. They should probably not be used if maximizing performance is the main o...
Definition: access.hpp:42
std::enable_if< std::is_arithmetic< T >::value, void >::type CEREAL_LOAD_FUNCTION_NAME(BinaryInputArchive &ar, T &t)
Loading for POD types from binary.
Definition: binary.hpp:126
std::enable_if< std::is_arithmetic< T >::value, void >::type CEREAL_SAVE_FUNCTION_NAME(BinaryOutputArchive &ar, T const &t)
Saving for POD types to binary.
Definition: binary.hpp:118
CEREAL_SIZE_TYPE size_type
The size type used by cereal.
Definition: helpers.hpp:61