I am writing a java backed webscript to upload a file into the Alfresco repository,
My challenge is that the i dont understand how to create a directory in the repository for the file
this is my code
String nodePath = "" + repository.getCompanyHome();
System.out.println("File name is " + filefield.getFilename());
InputStream fileContent=filefield.getContent().getInputStream();
File uploadedFile=new File(nodePath + "/" + filefield.getFilename());
FileWriter writer = new FileWriter(uploadedFile);
i keep getting an exception that the file i created is does not exist when i want to use it in the line
FileWriter writer = new FileWriter(uploadedFile);
which implies that the directory i specify for the file is invalid
Please i need help on this