Here you can find the source of toResourcePath(String fileName)
public static String toResourcePath(String fileName)
//package com.java2s; //License from project: Apache License import java.nio.file.Paths; public class Main { public static String toResourcePath(String fileName) { return Paths.get("src", "main", "resources", fileName).toString(); }//from w ww . j a v a2s . c o m }