C
Christopher
I would like to make a template data structure such that any type of
data structure may be contained within the template object with the
constraint that the object being contained must have a specific data
member of a specific type. Does there exist a c++ construct to
accomplish this task?
EX
template class container
{
methods
..
..
..
Data * list_of_data; // Instead of type Data, could be any type.
};
class Data // Mock data type
{
methods
..
..
Bounding_Box bounds; // Must have this!
};
Not sure if that got my point across
Thanks,
Christopher
data structure may be contained within the template object with the
constraint that the object being contained must have a specific data
member of a specific type. Does there exist a c++ construct to
accomplish this task?
EX
template class container
{
methods
..
..
..
Data * list_of_data; // Instead of type Data, could be any type.
};
class Data // Mock data type
{
methods
..
..
Bounding_Box bounds; // Must have this!
};
Not sure if that got my point across
Thanks,
Christopher