title: Java 1.8 Windows Server 2016 file.isDirectory is always false
body: <p>I use Java 1.8 on Windows Server 2016, and my code contains a test condition like this:</p>
  
  <pre><code>String path = "\\myserver\folder";
  File file = new File(path);
  if(file.isDirectory())
      System.out.println("is a dir");
  else
      System.out.println("is not a dir");
  </code></pre>
  
  <p>but always the return value is false. I tried mapping, create a symlink.
  I tried also the java nio but nothing changed. Does anyone know why? Is it a bug of Windows or Java?</p>
  
  <p>Thanks</p>