title: Get full path of selected file in JSF
body: <p>I need a JSF button which allows user to browse and select a particular file, then I need my program to retrieve full path of the file. </p>
  
  <p>This functionality is required when user runs the client portion from the server itself (i.e. browses to the file in the same server which hosts the web app). If the user sends request from another machine, then uploading the file is enough.</p>
  
  <p>For now, I am using h:inputFile tag.</p>
  
  <pre><code> &lt;h:inputFile id="file" value="#{TrainingDirectoryBean.file}"&gt;&lt;/h:inputFile&gt;
  </code></pre>
  
  <p>My bean : TrainingDirectoryBean has the following property</p>
  
  <pre><code>protected Part file;
  </code></pre>
  
  <p>But I can't get full path from it. What is the solution?</p>