<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <title>java.io.File class and absolute Path</title>
  <link rel="self" href="https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=118977113" />
  <subtitle>java.io.File class and absolute Path</subtitle>
  <id>https://liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=118977113</id>
  <updated>2026-04-03T19:33:25Z</updated>
  <dc:date>2026-04-03T19:33:25Z</dc:date>
  <entry>
    <title>RE: java.io.File class and absolute Path</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=118982520" />
    <author>
      <name>ali yeganeh</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=118982520</id>
    <updated>2020-04-20T12:50:28Z</updated>
    <published>2020-04-20T12:50:28Z</published>
    <summary type="html">Thank you very much for your reply</summary>
    <dc:creator>ali yeganeh</dc:creator>
    <dc:date>2020-04-20T12:50:28Z</dc:date>
  </entry>
  <entry>
    <title>RE: java.io.File class and absolute Path</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=118977522" />
    <author>
      <name>David H Nebinger</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=118977522</id>
    <updated>2020-04-19T04:42:35Z</updated>
    <published>2020-04-19T04:42:35Z</published>
    <summary type="html">You cannot use a file reference because you&amp;#39;re inside of a jar, it&amp;#39;s not an actual file.&lt;br /&gt;&lt;br /&gt;Instead, use getClass().getResourceAsStream() to get to the actual resource.</summary>
    <dc:creator>David H Nebinger</dc:creator>
    <dc:date>2020-04-19T04:42:35Z</dc:date>
  </entry>
  <entry>
    <title>java.io.File class and absolute Path</title>
    <link rel="alternate" href="https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=118977112" />
    <author>
      <name>ali yeganeh</name>
    </author>
    <id>https://liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=118977112</id>
    <updated>2020-04-18T20:54:48Z</updated>
    <published>2020-04-18T20:54:48Z</published>
    <summary type="html">&lt;html&gt;&lt;head&gt;&lt;/head&gt;&lt;body&gt;Hi&lt;br&gt;When I create an object of&amp;nbsp; java.io.File class, absolutePath of my file is wrong .&lt;br&gt;&lt;pre&gt;&lt;code&gt;String path = "src/main/resources/myFile.jpg";
java.io.File file = new java.io.File( path );
System.out.println( file.getAbsolutePath() );&lt;/code&gt;&lt;/pre&gt;&lt;br&gt;&lt;br&gt;&lt;strong&gt;How can I solve this problem?&lt;/strong&gt;&lt;/body&gt;&lt;/html&gt;</summary>
    <dc:creator>ali yeganeh</dc:creator>
    <dc:date>2020-04-18T20:54:48Z</dc:date>
  </entry>
</feed>
