Note that there are some explanatory texts on larger screens.

plurals
  1. POMaven compilation fails while eclipse is successful
    text
    copied!<p>I am using maven3.03 and Eclipse 3.5 on Windows XP. I converted old web project to be in maven configuration style. <br> When i compile the project in eclipse everything compile.<br>Note: The classpath contains: Maven Dependencies and JDK(1.6_018).<br> When i compile from command line using mvn, I get few errors:<br> 1.package com.sun.xml.internal.stream.buffer.stax does not exist.<br> 2.package com.sun.xml.internal.stream.writers does not exist<br> 3.cannot find symbol - symbol : class XMLDOMWriterImpl<br> 4.package com.sun.xml.internal.messaging.saaj.util does not exist<br> 5.package com.sun.xml.internal.bind.v2.runtime.unmarshaller does not exist<br> 6.cannot find symbol - symbol : class NamespaceContexHelper<br> 7.cannot find symbol symbol : class ByteOutputStream</p> <p>I can see that this something with sun jar. But i just can not understand why eclipse is ok and command line is not.</p> <p><strong>EDIT</strong>: One of the errors i didn't mention in the above list is:<br></p> <pre><code>[ERROR]&lt;path&gt;\EventsViewer.java:[54,69] inconvertible types found: &lt;br&gt;java.util.SortedMap&lt;java.util.Date,java.util.List&lt;com.myClass&gt;&gt; required: java.util.Map&lt;? extends java.util.Date,? extends java.util.List&lt;com.myOtherClass&gt;&gt; </code></pre> <p><br> When i see the same line in eclipse i get warning: </p> <pre><code>Type safety: Unchecked cast from SortedMap&lt;Date,List&lt;myClass&gt;&gt; to Map&lt;? extends Date,? extends List&lt;myOtherClass&gt;&gt; </code></pre> <p>In Eclipse i get warning and in maven i get error. I did check the org.eclipse.jdt.core.prefs and see the setting is org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning. <br><br><strong>Update</strong>: I got read of some of the above errors. The "problem" is that in eclipse it appears as unused import. Stangly maven report this as error. After removing this unused import the error was gone. But still problem 3 and 7 occures<br><br> <strong>Conclusion</strong>: I guess that the warnings become errors in the javac. since I don't use any supressWarnings. I am just surprised that the error is different. What is it?</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload