Should all methods be static if their class has no member variables

The class you describe is simply just a set of functions that operate on inputs only. It’s perfectly reasonable to make such functions static methods of a class. Doing so groups them logically and eliminates possible name conflicts. The class in fact acts as a namespace and nothing more.

Leave a Comment