title: Loading properties file gives null
body: <p>In the <code>main()</code> class i put a code:</p>
  
  <pre><code>App.getClass().getClassLoader().getResourceAsStream("Repo-Offer.properties")
  </code></pre>
  
  <p>the result is <code>null</code></p>
  
  <p>The property file resides in:</p>
  
  <pre><code>Project/src/main/resources/properties/Repo-Offer.properties 
  </code></pre>
  
  <p>I was trying to load properties like this:</p>
  
  <pre><code>private Properties getPropertiesFromClasspath(String propFileName) throws IOException {
      // loading xmlProfileGen.properties from the classpath
      Properties props = new Properties();
      InputStream inputStream = this.getClass().getClassLoader()
          .getResourceAsStream(propFileName);
  
      if (inputStream == null) {
          throw new FileNotFoundException("property file '" + propFileName
              + "' not found in the classpath");
      }
  
      props.load(inputStream);
  
      return props;
  }
  </code></pre>
  
  <p>but because of that null it says</p>
  
  <pre><code>  Exception in thread "main" java.io.FileNotFoundException: Repo-Offer.properties
  </code></pre>
  
  <p>How to use the properties files from:
      Project/src/main/resources/properties/Repo-Offer.properties 
  while the source is in </p>
  
  <pre><code>Project/src/main/java/com/...
  </code></pre>
  
  <p>?
  <strong>EDIT
  It is Maven project.</strong></p>