Hot answers tagged

5

Generally there are two schools of thought on this: Multiple types with the same name are fine if the name makes sense for them all. Differentiate them via a package/namespace/module etc name. Avoid multiple types with the same name as one then has to reply on the package/namespace/module etc name to differentiate them, which can be confusing. As a general ...


5

"File Path" is a noun phrase. You want to find a way to explain the syntax of noun phrases in english, in particular where the head noun appears (at the end in this and similar phrases), and that the the value returned should be an instance of the thing named by the head noun. Your function presumably returns a path, in particular the path of a file. If you ...


5

I cannot figure out a good way to explain why words should be in a specific order, except for "It how it's written in English" That's because it is the only reason for writing it this way. There is a naive view that there is a consensus that all programming should be done in american English. But this isn't really the case, let the developers choose ...


1

It looks like it is a utility class. It's common to just name is WhateverItIsUtil but you need to ask yourself if they would be better placed in the class they are used on. Also, I don't think you should name it a verb. Many might also name it a SomethingManager. Obviously if you need to share the methods with many classes then you might feel stuck with ...


Only top voted, non community-wiki answers of a minimum length are eligible