Package org.eclipse.core.resources

Examples of org.eclipse.core.resources.IResource.refreshLocal()


    if (outputFolderPath.length() != 0) {
      // If the output directory is set and inside the workspace it will be refreshed
      IResource result = ResourcesPlugin.getWorkspace().getRoot().findMember(outputFolderPath);
     
      if (result != null)
          result.refreshLocal(IResource.DEPTH_INFINITE, null);
    }
  }
}
View Full Code Here


            IPath p = (IPath) path.clone();
            while (p.segmentCount() > 0) {
                p = p.removeLastSegments(1);
                IResource resource = ResourcesPlugin.getWorkspace().getRoot().findMember(p);
                if (resource != null) {
                    resource.refreshLocal(2, null);
                    return;
                }
            }
        } catch (Exception e) {
            logger.logError("While refreshing path " + path, e);
View Full Code Here

    public static void refreshFile(File f) throws Exception {
        String path = toLocal(f);
        IResource r = ResourcesPlugin.getWorkspace().getRoot().findMember(path);
        if (r != null) {
            r.refreshLocal(IResource.DEPTH_INFINITE, null);
        }
    }

    public static void refresh(Project p) throws Exception {
        IJavaProject jp = getJavaProject(p);
View Full Code Here

            IPath p = (IPath) path.clone();
            while (p.segmentCount() > 0) {
                p = p.removeLastSegments(1);
                IResource resource = ResourcesPlugin.getWorkspace().getRoot().findMember(p);
                if (resource != null) {
                    resource.refreshLocal(2, null);
                    return;
                }
            }
        } catch (Exception e) {
            logger.logError("While refreshing path " + path, e);
View Full Code Here

    public static void refreshFile(File f) throws Exception {
        String path = toLocal(f);
        IResource r = ResourcesPlugin.getWorkspace().getRoot().findMember(path);
        if (r != null) {
            r.refreshLocal(IResource.DEPTH_INFINITE, null);
        }
    }

    public static void refresh(Project p) throws Exception {
        IJavaProject jp = getJavaProject(p);
View Full Code Here

            final IPath out = properties.getOutputDir();
            final IResource outr = project.findMember(out);
            if (outr != null) {
                try {
                    outr.setDerived(true, null);
                    outr.refreshLocal(IResource.DEPTH_ZERO, null);
                } catch (final CoreException e) {
                    // ignore it
                }
            }
View Full Code Here

        final IErlProject erlProject = ErlangEngine.getInstance().getModel()
                .getErlangProject(project);
        final IPath outputDir = erlProject.getProperties().getOutputDir();
        final IResource ebinDir = project.findMember(outputDir);
        if (ebinDir != null) {
            ebinDir.refreshLocal(IResource.DEPTH_ONE, null);
        }
    }

    public void completeCompile(final @NonNull IProject project, final IResource source,
            final OtpErlangObject compilationResult, final IOtpRpc backend,
View Full Code Here

                    e.printStackTrace();
                }
            }
            if (dir != null) {
                try {
                    dir.refreshLocal(IResource.DEPTH_ONE, null);
                } catch (final CoreException e) {
                }
            }
        }
    }
View Full Code Here

        final IPath out = properties.getOutputDir();
        final IResource outr = project.findMember(out);
        if (outr != null) {
            try {
                outr.setDerived(true, null);
                outr.refreshLocal(IResource.DEPTH_ZERO, null);
            } catch (final CoreException e) {
                // ignore it
            }
        }
View Full Code Here

   
    // refresh cas processor directory
    IResource processorFolder = mAnnotatorConfiguration.getBaseFolder();
   
    try {
      processorFolder.refreshLocal(IResource.DEPTH_INFINITE, monitor);
  } catch (CoreException e) {
    // maybe this fails, sorry
    CasEditorPlugin.log(e);
  }
  }
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.