July 13th, 2010, 08:36 AM
vectors of vectors of different types...
So my problem is that I need to create a data table in which each column is a vector that contains some sort of data that is read in from a file. The problem is that the table could have any dimensions, and each column can be one of many types (string, int, double, etc.). I would like to know if there is a way to create this object that I want. Right now I am attempting to do it using a template class:
The problem with this is that to instantiate a vector of asciiColumns I have to specify the type that asciiColumn should contain, and that defeats the purpose.
template <typename T2>
asciiColumn (vector<T2> invec)
vec = invec;
Any help with this solution or other proposed solutions would be much appreciated.
Tags for this Thread
Click Here to Expand Forum to Full Width
This a Codeguru.com survey!