title: GetResource method is not working in java 11
body: <p>This is my project structure:
  <a href="https://i.stack.imgur.com/55Ssk.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/55Ssk.png" alt="enter image description here"></a></p>
  
  <p>This is my module-info:</p>
  
  <pre><code>open module org.client.main {
      exports org.apj.client.app;
      requires javafx.controls;
      requires javafx.base;
      requires javafx.fxml;
      requires spring.context;
      requires spring.web;
      requires java.sql;
      requires spring.beans;
      requires spring.core;
  }
  </code></pre>
  
  <p>This is my parent gradle build file:</p>
  
  <pre><code>subprojects {
      afterEvaluate {
          repositories {
              jcenter()
          }
  
          compileJava {
              doFirst {
                  options.compilerArgs = [
                          '--module-path', classpath.asPath,
                  ]
                  classpath = files()
              }
          }
  
          compileTestJava {
              inputs.property("moduleName", moduleName)
              doFirst {
                  options.compilerArgs = [
                          '--module-path', classpath.asPath,
                          '--add-modules', 'junit',
                          '--add-reads', "$moduleName=junit",
                          '--patch-module', "$moduleName=" + files(sourceSets.test.java.srcDirs).asPath,
                  ]
                  classpath = files()
              }
          }
  
          test {
              inputs.property("moduleName", moduleName)
              doFirst {
                  jvmArgs = [
                          '--module-path', classpath.asPath,
                          '--add-modules', 'ALL-MODULE-PATH',
                          '--add-reads', "$moduleName=junit",
                          '--patch-module', "$moduleName=" + files(sourceSets.test.java.outputDir).asPath,
                  ]
                  classpath = files()
              }
          }
      }
  }
  </code></pre>
  
  <p>This is my client module build file:</p>
  
  <pre><code>plugins {
      id 'java'
  }
  
  group 'APJ'
  version '1.0-SNAPSHOT'
  
  sourceCompatibility = 11
  
  repositories {
      mavenCentral()
  }
  
  dependencies {
      compile group: 'org.springframework', name: 'spring-webmvc', version: '5.1.4.RELEASE'
      testCompile group: 'junit', name: 'junit', version: '4.12'
  }
  
  ext.moduleName = 'org.client.main'
  </code></pre>
  
  <p>I am trying to getResource for FXMLLoader but I simply can not get it to work. I have been struggling for 2 hours and I am really desperate right now. I have tried like every possible combination of file name, every possible location but still it is returning null.</p>
  
  <p>Also I have tried <code>ClassLoader.getSystemClassLoader().getResource("/login.fxml")</code>
  <code>getClass().getResource("/login.fxml")</code>
  But it is also not working.</p>
  
  <p>Can someone help me with this ? I would be very grateful.</p>