Java Resource Load getResourceFile(Class theClass, String fileName)

Here you can find the source of getResourceFile(Class theClass, String fileName)

Description

get Resource File

License

Apache License

Declaration

public static File getResourceFile(Class<?> theClass, String fileName) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

import java.io.File;

public class Main {
    public static File getResourceFile(Class<?> theClass, String fileName) {
        return new File(theClass.getResource(fileName).getFile());
    }/*from   w w  w .  j  a va2  s.c o m*/
}

Related

  1. getResourceBundleForLoc(String language, String fileName)
  2. getResourceBytes(String path)
  3. getResourceByZip(final ZipInputStream zipIN, final String resourcePath)
  4. getResourceDirectory()
  5. getResourceFile(Class clazz, String path)
  6. getResourceFile(String relativeResourceFilePathname)
  7. getResourceFile(String resource)
  8. getResourceFile(String resourceName)
  9. getResourceFromJar(File fromFile, String insideFile)