Examples of findResource()


Examples of org.atomojo.www.util.ResourceManager.findResource()

                  if (resourceName!=null) {
                     if (isFineLog) {
                        getLogger().fine("Using resource "+resourceName);
                     }
                     ResourceManager manager = (ResourceManager)getContext().getAttributes().get(ResourceManager.ATTR);
                     ResourceManager.Retriever retriever = manager.findResource(resourceName);
                     if (retriever!=null) {
                        remoteResponse = retriever.get();
                     } else {
                        getLogger().warning("No resource named "+resourceName);
                     }
View Full Code Here

Examples of org.eclipse.osgi.internal.loader.BundleLoader.findResource()

      Enumeration<URL> result = bundledata.findLocalResources(name);
      if (result != null && result.hasMoreElements())
        return result.nextElement();
      return null;
    }
    return loader.findResource(name);
  }

  public Enumeration<URL> getResources(String name) throws IOException {
    BundleLoader loader = null;
    try {
View Full Code Here

Examples of org.eclipse.osgi.internal.loader.BundleLoader.findResource()

      return null;
    }
    loader = checkLoader();
    if (loader == null)
      return null;
    return (loader.findResource(name));
  }

  public Enumeration getResources(String name) throws IOException {
    BundleLoader loader = null;
    try {
View Full Code Here

Examples of org.eclipse.sapphire.Context.findResource()

                    final String pname = p.getName().content();
                   
                    if( pname != null )
                    {
                        final String possibleFullPath = pname.replace( '.', '/' ) + "/" + string;
                        stream = ctxt.findResource( possibleFullPath );
                       
                        if( stream != null )
                        {
                            break;
                        }
View Full Code Here

Examples of org.jasig.portal.car.CarResources.findResource()

    private File getCarFile() throws PortalException
    {
        if (mCarFile == null)
        {
            CarResources cRes = CarResources.getInstance();
            URL classUrl = cRes.findResource(mClassFilePath);
            if (classUrl == null)
                throw new PortalException(
                        "Unable to locate CAR containing compiled " +
                        "controller class file '" + mClassFilePath + "'.");
            String carPath = classUrl.toExternalForm();
View Full Code Here

Examples of org.jconfig.utils.ResourceLocator.findResource()

     */
    public Configuration load(String configurationName) throws ConfigurationManagerException {
        String fileName = configurationName+"_config.script";
        try {
            ResourceLocator locator = new ResourceLocator(fileName);
            InputStream is = locator.findResource(fileName);
            BufferedReader nis = new BufferedReader(new InputStreamReader(is));           
            String line;
            Vector content = new Vector();
            while ((line=nis.readLine()) != null ) {
                content.add(line);
View Full Code Here

Examples of org.jconfig.utils.ResourceLocator.findResource()

     */
    public Configuration load(String configurationName) throws ConfigurationManagerException {
        fileName = configurationName+"_config.script";
    try {
      ResourceLocator locator = new ResourceLocator(fileName);
      InputStream is = locator.findResource(fileName);
      return load(configurationName,is);
    }
    catch (IOException e) {
      ErrorReporter.getErrorHandler().reportError("Error while trying to read file",e);
            throw new ConfigurationManagerException("Error while trying to read file");
View Full Code Here

Examples of org.jnode.vm.VmSystemClassLoader.findResource()

        out.println("; " + destFile.getPath());
        out.println("; THIS file has been generated automatically on " + new Date());
        out.println();

        for (ClassName cn : classes) {
            lastModified = Math.max(lastModified, cl.findResource(cn.getClassFileName()).
                openConnection().getLastModified());
            out.println("; Constants for " + cn.getClassName());

            if (cn.isStatic()) {
                Class<?> cls = Class.forName(cn.getClassName());
View Full Code Here

Examples of org.mule.module.launcher.MuleApplicationClassLoader.findResource()

                {
                    MuleApplicationClassLoader muleCL = (MuleApplicationClassLoader) ccl;
                    // check if there's an app-specific logging configuration available,
                    // scope the lookup to this classloader only, as getResource() will delegate to parents
                    // locate xml config first, fallback to properties format if not found
                    URL appLogConfig = muleCL.findResource("log4j.xml");
                    if (appLogConfig == null)
                    {
                        appLogConfig = muleCL.findResource("log4j.properties");
                    }
                    final String appName = muleCL.getAppName();
View Full Code Here

Examples of org.netbeans.api.java.classpath.ClassPath.findResource()

        if (i > 0) {
            resourceName = resourceName.substring(0, i);
        }
        FileObject[] sRoots = SourceForBinaryQuery.findSourceRoots(root.toURL()).getRoots();
        ClassPath sourcePath = ClassPathSupport.createClassPath(sRoots);
        FileObject rfo = sourcePath.findResource(resourceName + ".java");
        if (rfo == null) {
            return null;
        }
        return rfo.toURL().toExternalForm();
    }
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.