docs: public synchronized void setFactoryMethod(String factoryMethodName)
      {
          Method newMethod = null;
          this.factoryMethodName = factoryMethodName;
  
          if (factoryMethodName != null)
          {
              try
              {
                  // see if we have a publicly accessible method by the name
                  newMethod = getFactoryClass().getMethod(factoryMethodName, NO_PARAMS);
              }
              catch (NoSuchMethodException e)
              {
                  try
                  {
                      // no publicly accessible method, see if there is a private/protected one
                      newMethod = getFactoryClass().getDeclaredMethod(factoryMethodName, NO_PARAMS);
                  }
                  catch (NoSuchMethodException e2)
                  {
                      // there is no such method available
                      throw new MetadataException(
                          "Invalid factory method, there is not"
                              + " a zero argument method named "
                              + factoryMethodName
                              + " on class "
                              + getFactoryClass().getName()
                              + ".");
                  }
              }
          }
          setFactoryMethod(newMethod);
      }