What should I name my factories' methods?
getX() are typically considered accessors of the object's intrinsic properties. However, factories supply instances of classes that are not associated in any way with the factory. They may or may not be created ahead of the call.
public class Robots { private static final Robot robot = new Robot(); private Robots() { } // or probably just robot() public static Robot getRobot() { return robot; } } createX()/makeX() would unnecessarily expose the fact that the factory creates a new instance (or worse, mislead).
Omitting get is a common practice in Spring @Configuration classes. The methods are typically never invoked in the code, though.
However, some believe Robots.robot() sounds awkward.
I am about to deploy an artifact. I don't feel like breaking and fixing my library's clients some time later just because I made up my mind and decided to rename getRobot() to robot() (or the opposite).
@Deprecated.@Deprecatedmethods lingering in the codebase for many years. It's about as helpful asTODOcomments (not helpful at all)