public static URL getURLFromPath(String path, BaseApplet applet)
    {
        URL url = null;
        try {
            if ((url == null) && (path != null))
                url = new URL(path);
        } catch (MalformedURLException ex) {
            Application app = null;
            if (applet == null)
            	applet = (BaseApplet)BaseApplet.getSharedInstance().getApplet();
            if (applet != null)
            	app = applet.getApplication();
            if ((app != null) && (url == null) && (path != null))
                url = app.getResourceURL(path, applet);
            else
                ex.printStackTrace();
        }
        return url;
    }
public static URL getURLFromPath ( String path , BaseApplet applet ) { URL url = null ; try { if ( ( url == null ) && ( path != null ) ) url = new URL ( path ) ; } catch ( MalformedURLException ex ) { Application app = null ; if ( applet == null ) applet = ( BaseApplet ) BaseApplet . getSharedInstance ( ) . getApplet ( ) ; if ( applet != null ) app = applet . getApplication ( ) ; if ( ( app != null ) && ( url == null ) && ( path != null ) ) url = app . getResourceURL ( path , applet ) ; else ex . printStackTrace ( ) ; } return url ; }
Get the URL from the path.
@param The resource path.
@return The URL.