I'm not sure where my problem fits, but because it's related to
EJB, i post it here
.
Here is the situation :
I want to apply for a job. The company requires the applicants to create an EJB application implementing an interface given by the company. From my application, i will get the home object, create the ejb object, and pass my data by calling the corresponding method.
Then, i need to jar them all(classes, my CV) and upload the jar-bundle to them, via their upload-servlet@their web page. My app will get executed there, and the if any runtime errors occur, they'll get printed on my browser.
Here's my problem :
One of the required method in my class was meant to read my CV which is in word-format.
jobApplication.setCurriculumVitae(byte[] buff);
The buff represents my CV.doc binary. Here comes the problem.
How do i read my data from a file which is inside a jar file ? I've tried several ways. I've tried out the plain FileInputStream which results in FileNotFoundException. I've tried out ClassLoader.getSystemResourceAsStream("CV.doc"), and it apparently returns null. Please help.