I would like to convert a procedural database program that I have created to an object oriented program. In my procedural program I use a struct:
struct shoes{
char Name[20];
int Number;
double ShoeSize;
};
Putting this into a class would I simply use:
class Shoes{
public:
//Function declerations
private:
chat Name[20]
int Number;
double ShoeSize;
};
Originally I passed the struct between functions, for example:
void view(Shoes *Shoe);
Can I do the same with the class? would this pass all the variables or would I have to separetly pass each variable? if not what is the best way to pass these variables as a group while using classes? would it be normal to use a struct inside a class?