|
Boost Users : |
From: Steven Watanabe (watanabesj_at_[hidden])
Date: 2008-03-29 13:08:10
AMDG
Robert Dailey wrote:
>
> You could put the ID in the base Packet type. That should
> minimize the
> chances of mismatch.
>
>
> Right now I'm already putting the ID as a static constant variable in
> each derived type. I don't see a way to set the ID in the base Packet
> class, since that would more than likely require CRTP or something.
> From what I have seen the Packet base class cannot be a template. I
> suppose you could do this if you used 3 levels of inheritance, but
> that seems ugly.
I'm thinking of a non static member variable in the base class, which
can be set in
the constructor.
In Christ,
Steven Watanabe
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