You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Reinhard Poetz <re...@apache.org> on 2004/12/16 12:10:00 UTC
Auto-Compling classes located in packages
While working with the new auto-compiling classloader I came across a problem:
- I created a new package "yyy" in WEB-INF/src
- Then I added the class "Reinhard"
At the console I get following error message:
------------------------------------------------------------------------------------
* created dir F:\os\cocoon\trunk\build\webapp\WEB-INF\src\yyy
* created file F:\os\cocoon\trunk\build\webapp\WEB-INF\src\yyy\Reinhard.java
removing resource xxx\Reinhard
yyy\Reinhard.java (16) : The declared package does not match the expected packag
e
yyy\Reinhard.java (21) : The public type Reinhard must be defined in its own fil
e
2 errors, 0 warnings
removing resource yyy\Reinhard
reloading
------------------------------------------------------------------------------------
Here the class:
------------------------------------------------------------------------------------
package yyy;
public class Reinhard {
public void test() {
System.out.println("Reinhard!");
}
}
------------------------------------------------------------------------------------
Adding a class at the root directory works well. I don't understand what I'm
doing wrong because classes in other packages work well.
- o -
BTW, I changed the FlowscriptInterpreter to use the thread classloader instead
of the former implementation of the compiling classloader. Right?
--
Reinhard
Re: Auto-Compling classes located in packages
Posted by Reinhard Poetz <re...@apache.org>.
Reinhard Poetz wrote:
> I'm doing wrong because classes in other packages work well.
^^^^^
the already existing packages
needed for the javaflow samples
--
Reinhard
Re: Auto-Compling classes located in packages
Posted by Torsten Curdt <tc...@apache.org>.
Hm... this works for me as well
* changed dir /home/tcurdt/dev/cocoon-trunk/build/webapp/WEB-INF/src
* created dir /home/tcurdt/dev/cocoon-trunk/build/webapp/WEB-INF/src/test
* created file
/home/tcurdt/dev/cocoon-trunk/build/webapp/WEB-INF/src/test/Test.java
storing class test.Test
parsing test.Test
saving test.Test class information in BCEL repository
0 errors, 0 warnings
Please restart cocoon and send me the output of the CCL.
> BTW, I changed the FlowscriptInterpreter to use the thread classloader
> instead of the former implementation of the compiling classloader. Right?
That should be cool.
cheers
--
Torsten