Re: Non *.java files as java acociation in Eclipse



On 2-8-2006 14:02, sarsonj@xxxxxxxxx wrote:
Hi Roland,

thank you for reply - this helps with editors, thank you. But there is
still problem, that for example package explorer didn't think, this is
Java file and didn't work with this as a Java class. For example, it
doesn't compile automaticaly and I cannot find it using Class browser
etc. Is there any sollution to tell Eclipse, that is shlould handle
this files as regular Java?


I don't think that is possible with Eclipse (at least not without some custom written plugin). Couldn't find it mentioned in the JLS (Java Language Specification), but the commandline compiler (javac) mandates that Java source files have .java suffixes (see <http://java.sun.com/j2se/1.5.0/docs/tooldocs/windows/javac.html>). Eclipse probably follows this convention.

What is the reason that you cannot just have *.java file names?
--
Regards,

Roland
.



Relevant Pages

  • Re: Does any one use blueJ
    ... Im doing this course from a book caleed object of java ... when I take the last java class in my major. ... people that prefer J-Edit over eclipse. ...
    (comp.lang.java.help)
  • while using javac -classpath some.jar some.java (Where does classpath get stored?)
    ... I hope I don't leave any vital information out. ... The jar and the java file both being in the same dir and I having ... recompile it without giving it the classpath. ... again to XP and I could still run and recompile the said .java file. ...
    (comp.lang.java.developer)
  • Java Compilation error using Eclipse
    ... I am not a very skilled java programmer, in fact this is the first big ... It contains several .java file and a .jar ... I was able to compile the project with netBeans, ... The declared package does not match the expected package ...
    (comp.lang.java.programmer)
  • while using javac -classpath some.jar some.java (Where does classpath get stored?)
    ... I hope I don't leave any vital information out. ... The jar and the java file both being in the same dir and I having ... recompile it without giving it the classpath. ... again to XP and I could still run and recompile the said .java file. ...
    (comp.lang.java.programmer)
  • while using javac -classpath some.jar some.java (Where does classpath get stored?)
    ... I hope I don't leave any vital information out. ... The jar and the java file both being in the same dir and I having ... recompile it without giving it the classpath. ... again to XP and I could still run and recompile the said .java file. ...
    (comp.lang.java.help)