You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Owen Thomas <ot...@wcg.net.au> on 2007/03/15 06:48:26 UTC
Generics and java version.
Hello.
Still new to Maven, I'm trying to port a project from Ant to Maven, and get the following error...
H:\CurrentProjects\JVMHost\src\main\java\au\net\wcg\jvmhost\CommandReturn.java:[18,18] generics are not supported in -source 1.3
[INFO](try -source 1.5 to enable generics)
I found this reference: http://forum.springframework.org/showthread.php?t=24913, but it talks of changing my "parent POM". I can still count the number of times I can count the times I've used Maven on one hand, and I am yet to receive enlightenment vis-à-vis the nature of the POM.
How do I get maven to compile my project under 1.5? If anyone uses Mavenide for NetBeans, knowing of a NB specific way of doing this would be great too.
Your help is greatly appreciated,
Owen.
Re: Generics and java version.
Posted by Wendy Smoak <ws...@gmail.com>.
On 3/14/07, Owen Thomas <ot...@wcg.net.au> wrote:
> How do I get maven to compile my project under 1.5?
Configure the compiler plugin for 1.5. There is an example here using 1.4.
http://maven.apache.org/plugins/maven-compiler-plugin/examples/set-compiler-source-and-target.html
--
Wendy
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: Generics and java version.
Posted by JesseLiu <je...@ecvision.com>.
add the following block to your pom.xml
<project>
....
<build>
....
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
JesseLiu
----- Original Message -----
From: "Owen Thomas" <ot...@wcg.net.au>
To: <us...@maven.apache.org>
Sent: Thursday, March 15, 2007 1:48 PM
Subject: Generics and java version.
Hello.
Still new to Maven, I'm trying to port a project from Ant to Maven, and get the following error...
H:\CurrentProjects\JVMHost\src\main\java\au\net\wcg\jvmhost\CommandReturn.java:[18,18] generics are not supported in -source 1.3
[INFO](try -source 1.5 to enable generics)
I found this reference: http://forum.springframework.org/showthread.php?t=24913, but it talks of changing my "parent POM". I can still count the number of times I can count the times I've used Maven on one hand, and I am yet to receive enlightenment vis-à-vis the nature of the POM.
How do I get maven to compile my project under 1.5? If anyone uses Mavenide for NetBeans, knowing of a NB specific way of doing this would be great too.
Your help is greatly appreciated,
Owen.
RE: Generics and java version.
Posted by Owen Thomas <ot...@wcg.net.au>.
Hello.
Thank you Jesse, Wendy, and others who may have replied subsequent to this message for helping. That appeared to do the trick.
Owen.
-----Original Message-----
From: Owen Thomas [mailto:othomas@wcg.net.au]
Sent: Thursday, March 15, 2007 4:48 PM
To: users@maven.apache.org
Subject: Generics and java version.
Hello.
Still new to Maven, I'm trying to port a project from Ant to Maven, and get the following error...
H:\CurrentProjects\JVMHost\src\main\java\au\net\wcg\jvmhost\CommandReturn.java:[18,18] generics are not supported in -source 1.3
[INFO](try -source 1.5 to enable generics)
I found this reference: http://forum.springframework.org/showthread.php?t=24913, but it talks of changing my "parent POM". I can still count the number of times I can count the times I've used Maven on one hand, and I am yet to receive enlightenment vis-à-vis the nature of the POM.
How do I get maven to compile my project under 1.5? If anyone uses Mavenide for NetBeans, knowing of a NB specific way of doing this would be great too.
Your help is greatly appreciated,
Owen.
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org