I've read a few threads related to the question by I'm still not sure what's better for the current situation. I have two simple classes:
File:
string name;
long size;
Folder:
string name;
IList<File> files;
IList<Folder> folders;
If I want to implement a method which calculates the contents size of a folder, should I implement it as an instance or as a static member. The implementation needs a Folder object as a sole parameter and it does not change any state of the variable so I'm thinking of making it static but I'm not sure if this is the right step.