My question is of a purely organisational nature and hence I realize potential answers may be subjective in nature. After years of working with C#, I've finally returned to C++ and am struggling with getting used to how to properly organise the files.
Basically, I want to know where the best places are to define predicates and function objects. Currently, I'm using a simple function object for an STL algorithm in a single class. This function object will not be useful to any other class, so where do I put it? Do I place it in the same namespace and in the header file or in the .cpp file? Do I place it in an anonymous namespace or do I put it in its own header/cpp file?
Thank you in advance for any and all answers,
Kevin