G
Guest
I've just been reading all about the Singleton class and understand how to
implement and use it but I cannot understand why one NEEDS to use it instead
of just declaring a class and implementing Public Static variables therein.
My usage revolves around global access to Reference Data. Some examples:
- Countries, States-Provinces, Cities, Area Codes
- Mobile Devices: Name, Description, Picture Filename
and other sorts of data that will rarely, if ever change. And since there
will always only need to be one copy of the data, going the Public Static
Variable route seems like the logical route.
Or am I missing something?
Robert W.
Vancouver, BC
implement and use it but I cannot understand why one NEEDS to use it instead
of just declaring a class and implementing Public Static variables therein.
My usage revolves around global access to Reference Data. Some examples:
- Countries, States-Provinces, Cities, Area Codes
- Mobile Devices: Name, Description, Picture Filename
and other sorts of data that will rarely, if ever change. And since there
will always only need to be one copy of the data, going the Public Static
Variable route seems like the logical route.
Or am I missing something?
Robert W.
Vancouver, BC