Examples of findResource()


Examples of java.net.URLClassLoader.findResource()

            URLClassLoader urlClassLoader = (URLClassLoader) classLoaderForResources;
            if (DEBUG) {
                System.out.println("Trying to load " + name + " using URLClassLoader.findResource");
                System.out.println("  from urls: " + Arrays.asList(urlClassLoader.getURLs()));
            }
            URL url = urlClassLoader.findResource(name);
            if (url == null) {
                url = urlClassLoader.findResource("/" + name);
            }
            if (IO.verifyURL(url)) {
                return url;
View Full Code Here

Examples of java.net.URLClassLoader.findResource()

                System.out.println("Trying to load " + name + " using URLClassLoader.findResource");
                System.out.println("  from urls: " + Arrays.asList(urlClassLoader.getURLs()));
            }
            URL url = urlClassLoader.findResource(name);
            if (url == null) {
                url = urlClassLoader.findResource("/" + name);
            }
            if (IO.verifyURL(url)) {
                return url;
            }
        }
View Full Code Here

Examples of java.net.URLClassLoader.findResource()

          e.printStackTrace();
        }
        if (null == checker ||
        // || null != checker.findResource("java/lang/Object.class")
        // //$NON-NLS-1$
            null != checker.findResource("org/apache/uima/impl/UIMAFramework_impl.class")) { //$NON-NLS-1$
          continue;
        }
      }
      if (result.length() > 0)
        result = result.append(PATH_SEPARATOR);
View Full Code Here

Examples of java.net.URLClassLoader.findResource()

      URL url = null;
      // First check for local visibility via a URLClassLoader.findResource
      if( loader instanceof URLClassLoader )
      {
         URLClassLoader ucl = (URLClassLoader) loader;
         defaultUrl = ucl.findResource(defaultsName);
         url = ucl.findResource(propertiesName);
         log.trace("findResource: "+url);
      }
      // Do a general resource search
      if( defaultUrl == null )
View Full Code Here

Examples of java.net.URLClassLoader.findResource()

      // First check for local visibility via a URLClassLoader.findResource
      if( loader instanceof URLClassLoader )
      {
         URLClassLoader ucl = (URLClassLoader) loader;
         defaultUrl = ucl.findResource(defaultsName);
         url = ucl.findResource(propertiesName);
         log.trace("findResource: "+url);
      }
      // Do a general resource search
      if( defaultUrl == null )
         defaultUrl = loader.getResource(defaultsName);
View Full Code Here

Examples of java.net.URLClassLoader.findResource()

      URL url = null;
      // First check for local visibility via a URLClassLoader.findResource
      if( loader instanceof URLClassLoader )
      {
         URLClassLoader ucl = (URLClassLoader) loader;
         url = ucl.findResource(propertiesName);
         log.trace("findResource: "+url);
      }
      if( url == null )
         url = loader.getResource(propertiesName);
      if( url == null)
View Full Code Here

Examples of java.net.URLClassLoader.findResource()

      URL rootURL = getResource("/vfs/test");
      VFS vfs = VFS.getVFS(rootURL);
      URL[] cp = {vfs.getRoot().toURL()};
      URLClassLoader ucl = new URLClassLoader(cp);
      // Search for a non-existent resource
      URL qp = ucl.findResource("nosuch-quartz.props");
      assertNull("findResource(nosuch-quartz.props)", qp);
      InputStream is = ucl.getResourceAsStream("nosuch-quartz.props");
      assertNull("getResourceAsStream(nosuch-quartz.props)", is);
   }
View Full Code Here

Examples of net.xoetrope.xui.XProject.findResource()

            startSettings.load( is );
            startSettings.put( "XDataSourceClass", "net.xoetrope.optional.data.XOptionalDataSource" );
            is.close();


            URL startupFile = theProject.findResource( theProject.getStartupFile());
            File outputFile = new File( startupFile.getFile());
            BufferedOutputStream bos = new BufferedOutputStream( new FileOutputStream( outputFile.toString() ));

            startSettings.store( bos, "XUI startup properties, automatically modified by XUI at " + new java.util.Date().toString());
            bos.flush();
View Full Code Here

Examples of org.apache.axis2.deployment.DeploymentClassLoader.findResource()

            DeploymentClassLoader urlCl = new DeploymentClassLoader(
                    new URL[]{deploymentFileData.getFile().toURL()}, null, prevCl);
            Thread.currentThread().setContextClassLoader(urlCl);

            // MediatorFactory registration
            URL facURL = urlCl.findResource(
                    "META-INF/services/org.apache.synapse.config.xml.MediatorFactory");
            if (facURL != null) {
                InputStream facStream = facURL.openStream();
                InputStreamReader facreader = new InputStreamReader(facStream);
View Full Code Here

Examples of org.apache.axis2.deployment.DeploymentClassLoader.findResource()

                handleException("Unable to find the MediatorFactory implementation. " +
                        "Unable to register the MediatorFactory with the FactoryFinder");
            }

            // MediatorSerializer registration
            URL serURL = urlCl.findResource(
                    "META-INF/services/org.apache.synapse.config.xml.MediatorSerializer");
            if (serURL != null) {
                InputStream serStream = serURL.openStream();
                InputStreamReader serReader = new InputStreamReader(serStream);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.