Boost logo

Boost Users :

Subject: Re: [Boost-users] [serialization] problems extending existing archivetype
From: Robert Ramey (ramey_at_[hidden])
Date: 2009-06-14 12:55:46


See the following changes help.

Robert Ramey

#define BOOST_ARCHIVE_SOURCE

>
>> #include <rs/repository/Archive.hpp>
>>
>> #include <rs/repository/Repository.hpp>
>>
>> namespace rs
>> {
>>
>> InputArchive::InputArchive( std::istream& is )
>> : boost::archive::xml_iarchive_impl<InputArchive>( is, 0 )
>> , m_repository( 0 )
>> {
>>
>> }
>>
>> InputArchive::InputArchive( std::istream& is, Repository&
>> repository ) :
>> boost::archive::xml_iarchive_impl<InputArchive>( is, 0 ) ,
>> m_repository( &repository ) {
>>
>> }
>>
>> Repository* InputArchive::GetRepository() const
>> {
>> return m_repository;
>> }
>>
>> } // end namespace rs
>>
>> BOOST_SERIALIZATION_REGISTER_ARCHIVE( rs::InputArchive )
>>
>> #include <boost/archive/impl/basic_xml_iarchive.ipp>
>> #include <boost/archive/impl/xml_iarchive_impl.ipp>
>>
>> namespace boost
>> {
>> namespace archive
>> {
>>
>> template class basic_xml_iarchive<rs::InputArchive>;
>> template class xml_iarchive_impl<rs::InputArchive>;
>>
template class detail::archive_pointer_iserializer<rs::InputArchive> ;

>> } // end namespace archive
>> } // end namespace boost
>>
>> #define BOOST_ARCHIVE_CUSTOM_IARCHIVE_TYPES rs::InputArchive
>


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net