A
Andrea Crotti
I open a new thread since the subject changed a little.
I have my own implementation of a RingBuffer (which I guess doens't work
correctly yet, but it's
http://gist.github.com/651951
which has a template parameter.
Now supposing I want to subclass it, how do I automatically get rid of
the template parameter?
I mean I want that my subclass is a RingBuffer of a certain type, and in
plus I'm adding a few methods
--8<---------------cut here---------------start------------->8---
class CoordRingBuffer : RingBuffer
{
private:
public:
CoordRingBuffer();
Coordinate average();
Coordinate min();
};
--8<---------------cut here---------------end--------------->8---
Could I simply make this
std::vector<T> buffer;
of a certain type?
I have my own implementation of a RingBuffer (which I guess doens't work
correctly yet, but it's
http://gist.github.com/651951
which has a template parameter.
Now supposing I want to subclass it, how do I automatically get rid of
the template parameter?
I mean I want that my subclass is a RingBuffer of a certain type, and in
plus I'm adding a few methods
--8<---------------cut here---------------start------------->8---
class CoordRingBuffer : RingBuffer
{
private:
public:
CoordRingBuffer();
Coordinate average();
Coordinate min();
};
--8<---------------cut here---------------end--------------->8---
Could I simply make this
std::vector<T> buffer;
of a certain type?