Revision: 185
          
http://mindtreeinsight.svn.sourceforge.net/mindtreeinsight/?rev=185&view=rev
Author:   bindul
Date:     2008-04-20 17:22:36 -0700 (Sun, 20 Apr 2008)

Log Message:
-----------
Added new log statements. Removed java compiler warnings.

Modified Paths:
--------------
    releng/maven-jsmooth-plugin/trunk/pom.xml
    
releng/maven-jsmooth-plugin/trunk/src/main/java/com/mindtree/techworks/insight/releng/mvn/jsmooth/FileUtils.java
    
releng/maven-jsmooth-plugin/trunk/src/main/java/com/mindtree/techworks/insight/releng/mvn/jsmooth/JSmoothCompileMojo.java

Modified: releng/maven-jsmooth-plugin/trunk/pom.xml
===================================================================
--- releng/maven-jsmooth-plugin/trunk/pom.xml   2008-04-21 00:11:30 UTC (rev 
184)
+++ releng/maven-jsmooth-plugin/trunk/pom.xml   2008-04-21 00:22:36 UTC (rev 
185)
@@ -26,7 +26,7 @@
        <parent>
                <groupId>com.mindtree.techworks.insight.releng</groupId>
                <artifactId>mvn-plugins-parent</artifactId>
-               <version>1.0.0</version>
+               <version>1.1.0-SNAPSHOT</version>
                <relativePath>../mvn-plugins-parent/pom.xml</relativePath>
        </parent>
        <modelVersion>4.0.0</modelVersion>

Modified: 
releng/maven-jsmooth-plugin/trunk/src/main/java/com/mindtree/techworks/insight/releng/mvn/jsmooth/FileUtils.java
===================================================================
--- 
releng/maven-jsmooth-plugin/trunk/src/main/java/com/mindtree/techworks/insight/releng/mvn/jsmooth/FileUtils.java
    2008-04-21 00:11:30 UTC (rev 184)
+++ 
releng/maven-jsmooth-plugin/trunk/src/main/java/com/mindtree/techworks/insight/releng/mvn/jsmooth/FileUtils.java
    2008-04-21 00:22:36 UTC (rev 185)
@@ -90,7 +90,7 @@
        public static void extractZipDirectories(ZipFile sourceFile,
                        File targetDirectory, String zipEntryFilter,
                        boolean excludeFiterInDest, Log log) throws IOException 
{
-               Enumeration entries = sourceFile.entries();
+               Enumeration<? extends ZipEntry> entries = sourceFile.entries();
                String entryFilter = (null == zipEntryFilter) ? "" : 
zipEntryFilter;
                int entryFilterLen = entryFilter.length();
                if (!targetDirectory.exists()) {
@@ -98,7 +98,7 @@
                }
                String targetPath = targetDirectory.getAbsolutePath();
                while (entries.hasMoreElements()) {
-                       ZipEntry entry = (ZipEntry) entries.nextElement();
+                       ZipEntry entry = entries.nextElement();
                        String entryName = entry.getName();
                        if (entryName.startsWith(entryFilter)) {
                                log.debug("Copying file: " + entryName);

Modified: 
releng/maven-jsmooth-plugin/trunk/src/main/java/com/mindtree/techworks/insight/releng/mvn/jsmooth/JSmoothCompileMojo.java
===================================================================
--- 
releng/maven-jsmooth-plugin/trunk/src/main/java/com/mindtree/techworks/insight/releng/mvn/jsmooth/JSmoothCompileMojo.java
   2008-04-21 00:11:30 UTC (rev 184)
+++ 
releng/maven-jsmooth-plugin/trunk/src/main/java/com/mindtree/techworks/insight/releng/mvn/jsmooth/JSmoothCompileMojo.java
   2008-04-21 00:22:36 UTC (rev 185)
@@ -196,8 +196,13 @@
 
                        File out = new File(project.getBuild().getDirectory(), 
model
                                        .getExecutableName());
+                       getLog().debug("Determined output file: " + 
out.getAbsolutePath());
+                       
                        SkeletonBean skel = 
skelList.getSkeleton(model.getSkeletonName());
                        File skelroot = skelList.getDirectory(skel);
+                       getLog().debug(
+                                       "Using skeleton [" + 
skel.getShortName() + "] from root ["
+                                                       + 
skelroot.getAbsolutePath() + "] ");
 
                        final ExeCompiler compiler = new ExeCompiler();
                        compiler.addListener(new ExeCompiler.StepListener() {
@@ -230,8 +235,10 @@
                        
                        return out;
                } catch (MojoExecutionException exc) {
+                       getLog().error("Error building the jsmooth wrapper", 
exc);
                        throw exc;
                } catch (Exception exc) {
+                       getLog().error("Error building the jsmooth wrapper", 
exc);
                        throw new MojoExecutionException(this, "Error building 
the jsmooth wrapper", exc.getMessage());
                }
 
@@ -380,9 +387,9 @@
                        getLog().debug(
                                        "Including dependencies with base 
scope: "
                                                        + dependencyScope);
-                       List impliedScopes = getImpliedScopes(dependencyScope);
+                       List<String> impliedScopes = 
getImpliedScopes(dependencyScope);
                        Set dependencyArtifacts = project.getArtifacts();
-                       ArrayList dependentArtifacts = new 
ArrayList(dependencyArtifacts
+                       ArrayList<String> dependentArtifacts = new 
ArrayList<String>(dependencyArtifacts
                                        .size());
 
                        String baseDir = "";
@@ -413,7 +420,7 @@
                                        Collections.addAll(dependentArtifacts, 
existingClasspath);
                                }
 
-                               jsmoothModel.setClassPath((String[]) 
dependentArtifacts
+                               jsmoothModel.setClassPath(dependentArtifacts
                                                .toArray(new 
String[dependentArtifacts.size()]));
                        }
                }
@@ -428,11 +435,11 @@
         * <li>test</li>
         * </ol>
         * 
-        * @param scope
-        * @return
+        * @param scope The scope defined in the input
+        * @return The list of implied scopes
         */
-       private List getImpliedScopes(String scope) {
-               List resolvedScopeList = new ArrayList();
+       private List<String> getImpliedScopes(String scope) {
+               List<String> resolvedScopeList = new ArrayList<String>();
 
                if (Artifact.SCOPE_COMPILE.equals(scope)) {
                        resolvedScopeList.add(Artifact.SCOPE_COMPILE);


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
MindTreeInsight-commits mailing list
MindTreeInsight-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mindtreeinsight-commits

Reply via email to