Package java.net

Examples of java.net.URI.normalize()


      wfResultItem.addLogInfo("Completed migration. URI: " + dgoCRef);
     
      // Add migration resulting text to metadata
      if (dgoCRef != null) {
        try {
          baseUri = new PDURI(dgoCRef.normalize()).formDataRegistryRootURI();
          wfResultItem.addLogInfo("migration base URI: " + baseUri);
     
          dgoC = dataRegistry.getDigitalObjectManager(baseUri).retrieve(dgoCRef)
          wfResultItem.addLogInfo("dgoC: " + dgoC.toString());
          if (dgoC != null && dgoB.getPermanentUri() != null) {
View Full Code Here


   
    private static String normaliseDataReference( String inUri ) {
        URI uri;
        try {
            uri = new URI(inUri);
            return uri.normalize().toASCIIString();
        } catch (Exception e) {
            log.error("Could not normalise: "+inUri);
        }
        return inUri;
    }
View Full Code Here

                            if (uri == null) {
                                continue;
                            }

                            String resourceName = uri.normalize().toString();

                            if (!resourceName.endsWith(".class") && matcher.doMatch(resourceName)) {
                                BeanDefinition scriptBean = createScriptBean(subElement, parserContext, resourceName,
                                                                             language, defaults);
                                String beanName = matcher.generateBeanName(resourceName, parserContext.getRegistry());
View Full Code Here

                            if (uri == null) {
                                continue;
                            }

                            String resourceName = uri.normalize().toString();

                            if (matcher.doMatch(resourceName)) {
                                BeanDefinition scriptBean = createScriptBean(subElement, parserContext, resourceName,
                                        language, defaults);
                                String beanName = matcher.generateBeanName(resourceName, parserContext.getRegistry());
View Full Code Here

     * place to store the output from a number of map-reduce tasks.
     */
    public static String makeStoreTmpPath(String orig) {
        Path path = new Path(orig);
        URI uri = path.toUri();
        uri.normalize();

        String pathStr = uri.getPath();
        if (path.isAbsolute()) {
            return new Path("abs"+pathStr).toString();
        } else {
View Full Code Here

        try {
            URI uri = new URI(arg);
            if ("file".equalsIgnoreCase(uri.getScheme())) {
                if (!uri.isOpaque()) {
                    return uri.normalize().toString();
                }
                return new File("").toURI().resolve(uri.getPath()).toString();
            } else {
                return normalize(arg);
            }
View Full Code Here

      File basedir = project.getBasedir();
      if(basedir != null)
        basedirURI = basedir.toURI();
      else
        basedirURI = URI.create(session.getExecutionRootDirectory());
      baseDir = new File(basedirURI.normalize());
    }
    return baseDir;
  }

  protected synchronized File getBuildDir() {
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.