title: java static class / variables
body: <p>Unsure about static variables.</p>
  
  <pre><code>import java.io.File;
  
  public class Logger {
      public static final File log = new File(File.listRoots()[0], "log.log");
      public static void log (String message) {
          /* ... */
      }
  }
  </code></pre>
  
  <p>Is the variable <code>log</code> pointing to the same memory throughout the life of the program? Basically is the <code>log</code> definition <code>new File(File.listRoots()[0], "log.log")</code> calculated multiple times or just one, and when?</p>
  
  <p>Thanks in advance.</p>