vectors,

Hello Prpgrammers,

Could any one help me with the meaning of this:

std::vector<AIDA::IHitogram1D*> histo;

AIDA is a namespace and IHistogram1D is a class defined inside it.

Tahnks in advance
closed account (N85iE3v7)
vector is a STL container, you can add elements to it ( primitives, objects, etc ) dynamically and it can grow as you add elements to it. To be short of course, STL, i.e. Standard Template Library is a topic for many books.

It seems that "histo" is collection of Histograms objects instantiated from the class "IHistogram1D"
closed account (yUq2Nwbp)
bbcc vector is standart template container.....it has this view

vector<type> array(10)..... argument isn't necessary...your type can be both from standart types and types defined by users......for example

vector<int>,vector<char*>,vector<Dog>........suppose Dog is class.....

the same situation is in your example.....IHistogram1D is type and your vector container contains members which are type of IHistogram1D*....
Topic archived. No new replies allowed.