Package org.eclipse.emf.ecore.resource

Examples of org.eclipse.emf.ecore.resource.URIConverter.normalize()


            found = false;
            i++;
            //TODO Add file extension name to ProjectElement
            uri = generateResourceName(projectPath, projectElement, i);

            URI normalizedURI = uriConverter.normalize(uri);
            for (Resource resource2 : list) {
                if (uriConverter.normalize(resource2.getURI()).equals(normalizedURI)) {
                    found = true;
                    break;
                }
View Full Code Here


            //TODO Add file extension name to ProjectElement
            uri = generateResourceName(projectPath, projectElement, i);

            URI normalizedURI = uriConverter.normalize(uri);
            for (Resource resource2 : list) {
                if (uriConverter.normalize(resource2.getURI()).equals(normalizedURI)) {
                    found = true;
                    break;
                }
            }
            if (!found) {
View Full Code Here

        return resource;
      }
    }

    URIConverter theURIConverter = getURIConverter();
    URI normalizedURI = theURIConverter.normalize(uri);
   
    Iterator<Resource> it = getResources().iterator();
    while (it.hasNext()) {
      Resource resource = it.next();     
      if (theURIConverter.normalize(resource.getURI()).equals(
View Full Code Here

    URI normalizedURI = theURIConverter.normalize(uri);
   
    Iterator<Resource> it = getResources().iterator();
    while (it.hasNext()) {
      Resource resource = it.next();     
      if (theURIConverter.normalize(resource.getURI()).equals(
          normalizedURI)) {
        if (loadOnDemand && !resource.isLoaded()) {
          demandLoadHelper(resource);
        }
View Full Code Here

               
    // System.out.println("ResourceChanged: " + file  );
    URI uri = URI.createPlatformResourceURI( file.getFullPath().toString() ) ;   
    // System.out.println("    ResourceURI: " + uri );   
    URIConverter theURIConverter = getURIConverter();
    URI normalizedURI = theURIConverter.normalize(uri);
       
    if (uriResourceMap != null) {
      uriResourceMap.remove(uri);
      uriResourceMap.remove(normalizedURI);
      // System.out.println("Removed from Map: " + map );
View Full Code Here

        return resource;
      }
    }

    URIConverter theURIConverter = getURIConverter();
    URI normalizedURI = theURIConverter.normalize(uri);
    for (Resource resource : getResources())
    {
      if (theURIConverter.normalize(resource.getURI()).equals(normalizedURI))
      {
        if (loadOnDemand && !resource.isLoaded())
View Full Code Here

    URIConverter theURIConverter = getURIConverter();
    URI normalizedURI = theURIConverter.normalize(uri);
    for (Resource resource : getResources())
    {
      if (theURIConverter.normalize(resource.getURI()).equals(normalizedURI))
      {
        if (loadOnDemand && !resource.isLoaded())
        {
          demandLoadHelper(resource);
        }
View Full Code Here

    if(target == null)
      return null; // should disable the link as well

    final URIConverter uriConverter = o.eResource().getResourceSet().getURIConverter();
    final URI uri = target.getEObjectURI();
    final URI normalized = uriConverter.normalize(uri);
    return normalized;
  }

  @Override
  protected String getFirstLine(EObject o) {
View Full Code Here

    if(!isAcceptableTarget(to))
      return;
    final URIConverter uriConverter = from.getResourceSet().getURIConverter();
    final String hyperlinkText = labelProvider.getText(to);
    final URI uri = to.getEObjectURI();
    final URI normalized = uriConverter.normalize(uri);

    XtextHyperlink result = getHyperlinkProvider().get();
    result.setHyperlinkRegion(region);
    result.setURI(normalized);
    result.setHyperlinkText(hyperlinkText);
View Full Code Here

      // use an URI Converter to allow possible model extender to rewrite
      // URI
      // TODO replace with ExtensibleURIConverterImpl once EMF dep moves
      // up to 2.4
      URIConverter uriConverter = new URIConverterImpl();
      URI uri = uriConverter.normalize(URI.createURI(name));

      // set Authority to host and port of the service
      final java.net.URI location = anIServiceInfo.getLocation();
      final String authority = location.getAuthority();
      uri = URI.createHierarchicalURI(uri.scheme(), authority,
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.