title: Can FileOutputStream() take a relative path as an argument
body: <p>I am creating a FileOutputStream object. It takes a file or String as an argument in its constructor.</p>
  
  <p>My question is, can I give it a relative URL as an argument for the location of a file, it doesn't seem to work, but I am trying to work out if this is possible at all (if not I will stop trying). </p>
  
  <p>If it is not possible, how can I (from a servlet) get the absolute path (on the filesystem, not the logical URL) to the current location in such a way that I can pass that to the constructor.</p>
  
  <p>Part of my problem is that my dev box is Windows but I will publish this to a Unix box, so the paths cannot be the same i.e. on Windows C:/.... and on unix /usr/...</p>