C++序列化库的实现(15)

// from
template<typename storage_class>
class wstring_iarchive : public basic_iarchive_impl<storage_class,storage_type::_WISTRING_TYPE>
{
public:
    wstring_iarchive(const storage_class& storage)
        :basic_iarchive_impl<storage_class,storage_type::_WISTRING_TYPE>(storage){}

~wstring_iarchive(){}
};

/// to
template<typename storage_class>
class wstring_oarchive : public basic_oarchive_impl<storage_class,storage_type::_WOSTRING_TYPE>
{
public:
    wstring_oarchive(storage_class& storage)
        :basic_oarchive_impl<storage_class,storage_type::_WOSTRING_TYPE>(storage){}

~wstring_oarchive(){}
};


NAMESPACE_SERIALIZATION_END
#endif

//xml_archive.hpp
#ifndef XML_ARCHIVE_INCLUDE
#define XML_ARCHIVE_INCLUDE

#include "archive_config.hpp"


NAMESPACE_SERIALIZATION_BEGIN

template<typename storage_class> class xml_iarchive;
template<typename storage_class> class xml_oarchive;


template<typename storage_class>
class xml_iarchive : public basic_iarchive_impl<storage_class,storage_type::_IXML_TYPE>
{
public:

xml_iarchive(const storage_class& storage)
        :basic_iarchive_impl<storage_class,storage_type::_IXML_TYPE>(storage){}

~xml_iarchive(){}

};


template<typename storage_class>
class xml_oarchive : public basic_oarchive_impl<storage_class,storage_type::_OXML_TYPE>
{
public:

xml_oarchive(storage_class& storage)
        :basic_oarchive_impl<storage_class,storage_type::_OXML_TYPE>(storage){}

~xml_oarchive(){}
};

NAMESPACE_SERIALIZATION_END
#endif

内容版权声明:除非注明,否则皆为本站原创文章。

转载注明出处:https://www.heiqu.com/4027141282656c44471a7b6eeb1dc451.html