I wrote a class that deals with a serial port (modem)it works, it's a static class, now I want to use three modems simultaneously, should I duplicate my class and attach each one to a separate modem?
If so, if I change the code in one class I should update the other classes.
Should I make my class non static?
If so, is there a way to instantiate only three instances of my class?
Aucun commentaire:
Enregistrer un commentaire