org.eclipse.oomph.resources

## Class ResourcesUtil

- java.lang.Object
- - org.eclipse.oomph.resources.ResourcesUtil

-     public final class ResourcesUtil
      extends Object

  Author:
    Eike Stepper

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `ResourcesUtil.ImportResult`
    `static interface` | `ResourcesUtil.RunnableWithFile`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static IMarker[]` | `buildWorkspace(boolean clean, String markerType)`
    `static void` | `clearWorkspace()`
    `static void` | `copyFile(IFile source, File target)`
    `static BackendResource` | `getBackendResource(IResource resource)`
    `static String` | `getProjectName(File folder)`
    `static ResourcesUtil.ImportResult` | `importProject(File projectLocation, IProgressMonitor monitor)`
    `static ResourcesUtil.ImportResult` | `importProject(File projectLocation, String projectName, IProgressMonitor monitor)`
    `static int` | `importProjects(Collection<File> projectLocations, IProgressMonitor monitor)`
    `static boolean` | `isLocal(IResource resource)`
    `static boolean` | `matchesPredicates(IProject project, EList<Predicate> predicates)`
    `static void` | `runWithFile(IProject project, IPath path, ResourcesUtil.RunnableWithFile runnable)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### getProjectName

          public static String getProjectName(File folder)
                                       throws ParserConfigurationException,
                                              Exception

      Throws:
        `ParserConfigurationException`
        `Exception`

    - #### getBackendResource

          public static BackendResource getBackendResource(IResource resource)

    - #### isLocal

          public static boolean isLocal(IResource resource)

    - #### runWithFile

          public static void runWithFile(IProject project,
                         IPath path,
                         ResourcesUtil.RunnableWithFile runnable)
                                  throws Exception

      Throws:
        `Exception`

    - #### copyFile

          public static void copyFile(IFile source,
                      File target)
                               throws CoreException,
                                      FileNotFoundException

      Throws:
        `CoreException`
        `FileNotFoundException`

    - #### importProjects

          public static int importProjects(Collection<File> projectLocations,
                           IProgressMonitor monitor)
                                    throws CoreException

      Throws:
        `CoreException`

    - #### importProject

          public static ResourcesUtil.ImportResult importProject(File projectLocation,
                                                 IProgressMonitor monitor)
                                                          throws Exception

      Throws:
        `Exception`

    - #### importProject

          public static ResourcesUtil.ImportResult importProject(File projectLocation,
                                                 String projectName,
                                                 IProgressMonitor monitor)
                                                          throws IOException,
                                                                 CoreException

      Throws:
        `IOException`
        `CoreException`

    - #### clearWorkspace

          public static void clearWorkspace()
                                     throws CoreException

      Throws:
        `CoreException`

    - #### buildWorkspace

          public static IMarker[] buildWorkspace(boolean clean,
                                 String markerType)
                                          throws CoreException

      Throws:
        `CoreException`

    - #### matchesPredicates

          public static boolean matchesPredicates(IProject project,
                                  EList<Predicate> predicates)

Copyright (c) 2014 Eike Stepper (Loehne, Germany) and others.
All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v2.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v20.html