How to arrange data in multiple class project

Jan 7, 2009 at 10:32pm
Hi!

I'm new to C++ and developing a project but I´m confused when deciding to place vectors/lists data types.

I don't know if the best way is to define them only in one class or to define them in the same class of the data type.

Can anyone explain the best way to do this?

thanks in advance;)
Jan 7, 2009 at 10:37pm
Can you please elaborate on your circumstances.
Jan 7, 2009 at 10:51pm
My project consists in registering invoices of transportation made by trucks.

I have two users class (employe and executive), one for invoice, one for client one for truck (who has two types of trucks) one for interface (reads input from users) and another one for system (loads information from files).

My question is where to define the vectors/lists and how to acess them.
Jan 8, 2009 at 12:30am
Define them within the classes that the data stored relates too.

e.g
class client would have a vector containing invoices if you wanted to store the invoices for each client like that.
Topic archived. No new replies allowed.