Package org.apache.maven.bootstrap.compile

Examples of org.apache.maven.bootstrap.compile.CompilerConfiguration


            }
        }

        if ( sourceDirectories != null )
        {
            CompilerConfiguration compilerConfiguration = new CompilerConfiguration();
            compilerConfiguration.setOutputLocation( outputDirectory );
            List classpathEntries = classpath( dependencies, extraClasspath, scope, resolver );
            compilerConfiguration.setNoWarn( true );
            compilerConfiguration.setClasspathEntries( classpathEntries );
            compilerConfiguration.setSourceLocations( Arrays.asList( sourceDirectories ) );

            /* Compile with debugging info */
            String debugAsString = System.getProperty( "maven.compiler.debug", "true" );

            if ( !Boolean.valueOf( debugAsString ).booleanValue() )
            {
                compilerConfiguration.setDebug( false );
            }
            else
            {
                compilerConfiguration.setDebug( true );
            }

            List messages = compiler.compile( compilerConfiguration );

            for ( Iterator i = messages.iterator(); i.hasNext(); )
View Full Code Here


            }
        }

        if ( sourceDirectories != null )
        {
            CompilerConfiguration compilerConfiguration = new CompilerConfiguration();
            compilerConfiguration.setOutputLocation( outputDirectory );
            List classpathEntries = classpath( dependencies, extraClasspath, scope, resolver );
            compilerConfiguration.setNoWarn( true );
            compilerConfiguration.setClasspathEntries( classpathEntries );
            compilerConfiguration.setSourceLocations( Arrays.asList( sourceDirectories ) );

            /* Compile with debugging info */
            String debugAsString = System.getProperty( "maven.compiler.debug", "true" );

            if ( !Boolean.valueOf( debugAsString ).booleanValue() )
            {
                compilerConfiguration.setDebug( false );
            }
            else
            {
                compilerConfiguration.setDebug( true );
            }

            List messages = compiler.compile( compilerConfiguration );

            for ( Iterator i = messages.iterator(); i.hasNext(); )
View Full Code Here

        sourceDirectories = new String[]{sourceDirectory};
      }
    }

    if (sourceDirectories != null) {
      CompilerConfiguration compilerConfiguration = new CompilerConfiguration();
      compilerConfiguration.setOutputLocation(outputDirectory);

      List classpathEntries = classpath(dependencies, extraClasspath, scope, resolver);

      compilerConfiguration.setNoWarn(true);
      compilerConfiguration.setClasspathEntries(classpathEntries);
      compilerConfiguration.setSourceLocations(Arrays.asList(sourceDirectories));

      Map<String,String> compilerOptions = new HashMap<String, String>();
      compilerOptions.putAll(compilerConfiguration.getCompilerOptions());

      String javaSpecificationVersionLevel = System.getProperty("java.specification.version.level");
      System.out.println("Java Specification Version Level: " + javaSpecificationVersionLevel);

      compilerOptions.put("-source", javaSpecificationVersionLevel);
      compilerOptions.put("-target", javaSpecificationVersionLevel);

      compilerConfiguration.setCompilerOptions(compilerOptions);

      /* Compile with debugging info */
      String debugAsString = System.getProperty("maven.compiler.debug", "true");

      if (!Boolean.valueOf(debugAsString)) {
        compilerConfiguration.setDebug(false);
      }
      else {
        compilerConfiguration.setDebug(true);
      }

      List messages = compiler.compile(compilerConfiguration);

      for (Object message : messages) {
View Full Code Here

            }
        }

        if ( sourceDirectories != null )
        {
            CompilerConfiguration compilerConfiguration = new CompilerConfiguration();
            compilerConfiguration.setOutputLocation( outputDirectory );
            List classpathEntries = classpath( dependencies, extraClasspath, scope, resolver );
            compilerConfiguration.setNoWarn( true );
            compilerConfiguration.setClasspathEntries( classpathEntries );
            compilerConfiguration.setSourceLocations( Arrays.asList( sourceDirectories ) );

            /* Compile with debugging info */
            String debugAsString = System.getProperty( "maven.compiler.debug", "true" );

            if ( !Boolean.valueOf( debugAsString ).booleanValue() )
            {
                compilerConfiguration.setDebug( false );
            }
            else
            {
                compilerConfiguration.setDebug( true );
            }

            List messages = compiler.compile( compilerConfiguration );

            for ( Iterator i = messages.iterator(); i.hasNext(); )
View Full Code Here

TOP

Related Classes of org.apache.maven.bootstrap.compile.CompilerConfiguration

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.