Examples of IResourceVisitor


Examples of org.eclipse.core.resources.IResourceVisitor

      }
    }
   
   
    IFolder moduleFolder = (IFolder) sourceFolder.getCorrespondingResource();
    moduleFolder.accept(new IResourceVisitor() {

      public boolean visit(IResource resource) throws CoreException {

        if(Util.isModuleXml(resource)) {
          try {
View Full Code Here

Examples of org.eclipse.core.resources.IResourceVisitor

          return true;
        }
      });
    } else {
      ResourcesPlugin.getWorkspace().getRoot().getFolder(outputLocation)
          .accept(new IResourceVisitor() {

            public boolean visit(IResource resource)
                throws CoreException {
              if (resource instanceof IFile) {
                IFile fl = (IFile) resource;
View Full Code Here

Examples of org.eclipse.core.resources.IResourceVisitor

                ITagDirRecord record = (ITagDirRecord) reference;
                IPath path = record.getPath();
                IResource found = ResourcesPlugin.getWorkspace().getRoot().findMember(path, false);

                try {
                  found.accept(new IResourceVisitor() {
                    public boolean visit(IResource resource) throws CoreException {
                      if (resource.getType() == IResource.FILE) {
                        addDependsOn(resource);
                      }
                      return true;
                    }
                  });
                }
                catch (CoreException e) {
                  Logger.logException(e);
                }
              }
                break;
              case (ITaglibRecord.URL) : {
                IURLRecord record = (IURLRecord) reference;
                String baseLocation = record.getBaseLocation();
                if (baseLocation != null && baseLocation.indexOf("://") < 0) {
                  IResource found = ResourcesPlugin.getWorkspace().getRoot().findMember(baseLocation, false);
                  if (found != null) {
                    try {
                      found.accept(new IResourceVisitor() {
                        public boolean visit(IResource resource) throws CoreException {
                          if (resource.getType() == IResource.FILE) {
                            addDependsOn(resource);
                          }
                          return true;
View Full Code Here

Examples of org.eclipse.core.resources.IResourceVisitor

      if (!configuration.getAttribute(IDebugConstants.VDM_LAUNCH_CONFIG_GENERATE_COVERAGE, true))// vdmProject.hasMeasurechecks())
      {
        model.arguments.put(DeModelConfig.LOAD_SETTING_DISABLE_COVERAGE, "true");
      }

      project2.accept(new IResourceVisitor()
      {

        public boolean visit(IResource resource) throws CoreException
        {
          if (resource instanceof IFile
              && resource.getFileExtension() != null
              && resource.getFileExtension().equals(DeModelConfig.LOAD_LINK))
          {
            model.arguments.put(DeModelConfig.LOAD_LINK, resource.getLocation().toFile().getAbsolutePath());
          }
          return true;
        }
      });

      p.getVdmModelFolder().accept(new IResourceVisitor()
      {

        public boolean visit(IResource resource) throws CoreException
        {
          if (vdmrtFileContentType.isAssociatedWith(resource.getName()))
View Full Code Here

Examples of org.eclipse.core.resources.IResourceVisitor

            monitor.worked(progress);

            if (!prj.isAccessible()) {
              continue;
            }
            prj.accept(new IResourceVisitor() {

              @Override
              public boolean visit(IResource resource)
                  throws CoreException {
                registerFitResouce(resource);
View Full Code Here

Examples of org.eclipse.core.resources.IResourceVisitor

    projects = ResourcesPlugin.getWorkspace().computeProjectOrder(projects).projects;
    dumpProjectReferences(projects);
   
    SysOutProgressMonitor.out.println("TOUCHING .classpath, .project AND org.eclipse.wst.common.component FILES TO RELOAD PROJECT DYNAMIC DEPENDENCIES:");
    wroot.accept(new IResourceVisitor(){

      public boolean visit(IResource res) throws CoreException
      {
        if (res.getType() == IResource.FILE)
        {
          if (res.getName().equals(".classpath") || res.getName().equals("org.eclipse.wst.common.component") || res.getName().equals(".project"))
          {
            res.touch(monitor);
          }
        }
        return true;
      }});

    projects = ResourcesPlugin.getWorkspace().computeProjectOrder(projects).projects;
    dumpProjectReferences(projects);
   
    SysOutProgressMonitor.out.println("SETTING .svn DIRECTORIES AS TEAM PRIVATE:");
   
    for (int i = 0; i < 3; i++)
    {
      wroot.accept(new IResourceVisitor(){

        public boolean visit(IResource res)
            throws CoreException
        {
          if (res.getName().equals(".svn"))
View Full Code Here

Examples of org.eclipse.core.resources.IResourceVisitor

  @SuppressWarnings("unchecked")
  void exportProducts(final IProgressMonitor monitor) throws Exception
  {
    final ArrayList products = new ArrayList();
    ResourcesPlugin.getWorkspace().getRoot().accept(new IResourceVisitor() {

      public boolean visit(final IResource res) throws CoreException
      {
        if (res.getName().endsWith(".product"))
        {
View Full Code Here

Examples of org.eclipse.core.resources.IResourceVisitor

 
  @SuppressWarnings("unchecked")
  void exportJars(final IProgressMonitor monitor) throws Exception
  {
    final ArrayList jardescs = new ArrayList();
    ResourcesPlugin.getWorkspace().getRoot().accept( new IResourceVisitor(){

      public boolean visit(IResource res) throws CoreException
      {
        if (res.getName().endsWith(".jardesc"))
        {
View Full Code Here

Examples of org.eclipse.core.resources.IResourceVisitor

                    });
                }
            } else if (event.getType() == IResourceChangeEvent.PRE_DELETE) {
                IResource resource = event.getResource();
                if (resource != null) {
                    resource.accept(new IResourceVisitor() {
                        public boolean visit(IResource resource) throws CoreException {
                            removeElementsFromResource(resource);
                            return true;
                        }
                    });
                }
            } else if (event.getType() == IResourceChangeEvent.PRE_CLOSE) {
                IResource resource = event.getResource();
                if (resource != null) {
                    resource.accept(new IResourceVisitor() {
                        public boolean visit(IResource resource) throws CoreException {
                            removeElementsFromResource(resource);
                            return true;
                        }
                    });
View Full Code Here

Examples of org.eclipse.core.resources.IResourceVisitor

  private void fullBuild(IProgressMonitor monitor) {
    final BaseLanguageRegistry languageReg = BaseLanguageRegistry.getInstance();
    final LinkedList<BuildInput> resources = new LinkedList<BuildInput>();

    try {
      getProject().accept(new IResourceVisitor() {
        Environment environment = SugarJParseController.makeProjectEnvironment(getProject());
       
        @Override
        public boolean visit(IResource resource) throws CoreException {
          Path root = new AbsolutePath(getProject().getLocation().makeAbsolute().toString());
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.