Current directory in vaadin

Hello !
I am working on reports. Now i have a jrxml file which i have to load so that i can parse it. However, the problem is, i want to load the file with its name directly

String path = “myreport.jrxml”;

But i am unable to find that where should i place that file in my project so that the above path is valid. In simple java project, we just place our desired file in our project folder where src folder is placed, but it is not working in vaadin project. So where should i place my file.

Thanks.

A Vaadin-Project is a Webproject, so you need to place your files either in a place accessible through the web (below “WebContent” in a Eclipse Dynamic Web Project) and use a proper URL or you place them in a Java-Package in your source-folder. In the latter case you need to fetch the resource using the ClassLoader / Class#getResourceAsStream().