Originally Posted by
Elysia
Why is MusicCD::addNewTracks asking for input and creating new audio tracks which it adds when the parameter MyTracks contains all the tracks to add?
Also let me ask with respect to which standard are you compiling? C++03 or C++11?
I'm trying to learn c+11. However, some books and examples are using old-style.
But my problem was qtcreator. I didn't know how can I setup to C++. And I found out! Everything is working with C+11.
I don't know how to use setters with cin. I read some examples, but usually they are on main function, and they use local variables to set constructors, like this:
Code:
std::cout << "Track Number: ";
std::cin >> trackno;
myTrack.setTrackNumber(trackno);
I want to know how can I use mutator functions to do so.
Other Problem that I'm facing is using the vector. I'm not sure that I'm thinking properly. My idea is: Collect data from user or an input (and later from file), set the the AudioTrack object with the correspondent attributes and then adding it to the Vector Mytracks.
A musicCD class is an abbstraction, a musicCD is a vector of tracks.
I changed my git. I think the name was too general. Probably in Future I'll create more examples, so this particular one, is a bookstore example
https://github.com/CreativeSoftware/...kStoreExample/