コード例 #1
0
  /**
   * Configures its debugging mode and classloader classpath from a given compiler configuration.
   * This cannot be done more than once due to limitations in {@link java.net.URLClassLoader
   * URLClassLoader}.
   */
  public void configure(CompilerConfiguration configuration) {
    super.configure(configuration);
    this.debug = configuration.getDebug();

    if (!this.configured && this.classLoader instanceof GroovyClassLoader) {
      appendCompilerConfigurationClasspathToClassLoader(
          configuration, (GroovyClassLoader) this.classLoader);
    }

    this.configured = true;
  }