Hi,
I would like to have (any kind of) a predefined list of strings in a namespace. The purose would be that it should be iterated e.g. to see what we have. I could use an array but in that case I can't tell safely how long it is. If I want to use eg. QStringList or the list<T> from the STL than I cannot fill it with the wanted values because there is no such constructor.
So this one works:
namespace myn
{
QString qs[] = {"first","second"};
}
but I cannot get the info how large my array is. What can I use instead?
Bookmarks