|
Boost Users : |
From: RIVASSEAU Jean Noel (JN.RIVASSEAU_at_[hidden])
Date: 2006-02-10 04:20:26
I already pointed this out to Robert, the correct use is on the cpp file, not the documentation.
I am also using no RTTI, for me it works fine except that I have to do all sort of strange things to get the thing to link correctly without multiple definitions.
Jean-Noël
-----Message d'origine-----
De : boost-users-bounces_at_[hidden] [mailto:boost-users-bounces_at_[hidden]] De la part de Alexandre Gacon
Envoyé : vendredi 10 février 2006 10:11
À : boost-users_at_[hidden]
Objet : Re: [Boost-users] [Serialization]Working without RTTI
I looked at the test_no_rtti.cpp and I have a question:
In the cpp file, the macro BOOST_CLASS_TYPE_INFO is used like this:
BOOST_CLASS_TYPE_INFO(
derived_base,
extended_type_info_no_rtti<derived_base>
)
But in the documentation, the macro is used like that:
BOOST_CLASS_TYPE_INFO(
derived_base,
extended_type_info_no_rtti<base_class>
)
What is the good use of the macro ?
Thank you
Alexandre Gacon
-----Message d'origine-----
De : boost-users-bounces_at_[hidden]
[mailto:boost-users-bounces_at_[hidden]] De la part de Robert Ramey
Envoyé : jeudi 9 février 2006 16:17
À : boost-users_at_[hidden]
Objet : Re: [Boost-users] [Serialization]Working without RTTI
I've included that facility and a test which demonstrates it.
test_no_rtti demonstrates how it can be used with a type_info facility which
uses the string associated with the type via BOOST_CLASS_EXPORT.
Other than that it hasn't been really tested/explored extensively.
After doing all this, it occurred to me that it RTTI would still be required
to serialize the std::vector etc. This could be worked around by some
combination of the above
a) implemented BOOST_CLASS_EXPORT for those serializations in the library
b) making a custom extended_type_info class which uses some other yet to be
determined method.
c) avoiding serialization of types not exported via pointers. That is, only
types serialized via pointers required RTTI. (at least that's the intention
- better test this!!)
Robert Ramey
Alexandre Gacon wrote:
> Hi,
>
> I would like to use the serialization library inside one of my project
> which do not use the RTTI. I produce a first version using
> boost::serialization::extended_type_info to produce the key associated
> to the class.
>
> Is it possible to use my own keys instead of the extended_type_info
> class to serialize my classes ?
>
> Thank you,
>
> Alexandre Gacon
> Project Manager
_______________________________________________
Boost-users mailing list
Boost-users_at_[hidden]
http://lists.boost.org/mailman/listinfo.cgi/boost-users
_______________________________________________
Boost-users mailing list
Boost-users_at_[hidden]
http://lists.boost.org/mailman/listinfo.cgi/boost-users
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