code: public static ClassReloadingStrategy of(Instrumentation instrumentation) {
          if (DISPATCHER.isRetransformClassesSupported(instrumentation)) {
              return new ClassReloadingStrategy(instrumentation, Strategy.RETRANSFORMATION);
          } else if (instrumentation.isRedefineClassesSupported()) {
              return new ClassReloadingStrategy(instrumentation, Strategy.REDEFINITION);
          } else {
              throw new IllegalArgumentException("Instrumentation does not support reloading of classes: " + instrumentation);
          }
      }
docs: Creates a class reloading strategy for the given instrumentation. The given instrumentation must either
  support {@link java.lang.instrument.Instrumentation#isRedefineClassesSupported()} or
  {@link java.lang.instrument.Instrumentation#isRetransformClassesSupported()}. If both modes are supported,
  classes will be transformed using a class retransformation.
  
  @param instrumentation The instrumentation to be used by this reloading strategy.
  @return A suitable class reloading strategy.