A static class should not work on an instance of an object. What then, identifies an instance of an object being “worked on”? Would this be anything concrete (i.e. pass in new ObjectA() to a a method’s parameters). So if this is what I see, the class should not be static.
Thanks
A static class simply means that there is only ONE instance of that object.A Static class simply behaves AS IF there was only one instance of it. Think of it as global; you cannot instantiate any objects of a static class. The values of member variable of the class will retain their value globally and you can ‘work’ on them with member functions.As opposed to a static class, with a non-static class you can create new objects and ‘work’ on these objects with member functions:
If this were to be a static class:
In the above example we created an object honda, of class type vehicle. We then ‘worked’ on the object with functions. For the static class, we
didn’t need tocannot create an object, we just call the class name instead of the object name (like honda).To recap:
Static = global, one instanceIf this doesn’t answer or address the question, please rephrase it with a clear question.