2020/6/3 19:31:13 -0700, mandy.ch...@oracle.com: > On 6/3/20 5:16 PM, Paul Sandoz wrote: >> Did you consider an alternative name, such as: >> >> /** >> * Initializes {@code targetClass}, if not already initialized. >> * ... >> */ >> public Class<?> initializeClass(Class<?> targetClass) ... >> >> ? > > I considered this. The targetClass may have been initialized. > `initializeClass` seems to be read that it should check if it's > initialized before calling?? I also considered `ensureInitialized` > which can be an option. I'm open to suggestion.
I agree that the `ensure` prefix is useful here. This method can only ensure that a class is initialized, so including `Class` in the method name seems redundant. I’d go with the shorter `ensureInitialized`. - Mark