title: Make Java Properties available across classes?
body: <p>I chose to take properties file for customization of some settings.
  I use the following code to make a Properties Object available in a class</p>
  
  <pre><code>Properties defaultProps = new Properties();
      try {
          FileInputStream in = new FileInputStream("custom.properties");
          defaultProps.load(in);
          in.close();
      } catch (Exception e) {
          e.printStackTrace();
      }
  </code></pre>
  
  <p>Do I have to add this to every class? Probably not because then every class would open a stream to this file.
  But I'm not sure how to handle this properly.
  Should I make a class <code>MyProperties</code> and instantiate it in whatever class needs properties?</p>
  
  <p>Thanks in advance!</p>