The pmtf_vector class allows us to store an array of uniform data. We need a way to store an array of arbitrary pmts - like the pmt map class. There are use cases where an array of pmts would be useful (such as getting the values from a map).
There is room for discussion here.
In pmts, there are tuples, vectors and lists are supported and in some cases have different syntax.
In python, there are tuples and vectors, where have fairly consistent syntax.
What do we want to support for pmts?
I'm going to define terms as follows:
vector - A contiguous array in memory holding the pmt pointers.
list - A linked list with each node holding a pmt pointer.
tuple - Same as vector, but elements are immutable.
I would vote for just supporting a vector. Note that the vector could be declared as const to support the equivalent of the tuple case. I don't think there are many use cases where a linked list would add a lot of value, but I'm open to other's opinions.
The pmtf_vector class allows us to store an array of uniform data. We need a way to store an array of arbitrary pmts - like the pmt map class. There are use cases where an array of pmts would be useful (such as getting the values from a map).
There is room for discussion here. In pmts, there are tuples, vectors and lists are supported and in some cases have different syntax. In python, there are tuples and vectors, where have fairly consistent syntax.
What do we want to support for pmts? I'm going to define terms as follows:
I would vote for just supporting a vector. Note that the vector could be declared as const to support the equivalent of the tuple case. I don't think there are many use cases where a linked list would add a lot of value, but I'm open to other's opinions.