Interface GroupProvider

All Known Implementing Classes:
FolderProvider

public interface GroupProvider
The Interface GroupProvider.
  • Method Summary

    Modifier and Type
    Method
    Description
    @NonNull String
    Gets the unique identifier of the grouping.
    @Nullable org.eclipse.core.runtime.IPath
    getParent(@NonNull org.eclipse.core.runtime.IPath path, @NonNull org.eclipse.core.resources.IProject project)
    Gets the parent path for the resource or group path.
    @NonNull Collection<org.eclipse.core.runtime.IPath>
    getParents(@NonNull org.eclipse.core.runtime.IPath path, @NonNull org.eclipse.core.resources.IProject project)
    Gets a collection of parent paths along the object path.
    @Nullable org.eclipse.core.runtime.IPath
    getPath(@NonNull Object group, @NonNull org.eclipse.core.resources.IProject project)
    Gets the path of the grouping object.
    @NonNull Collection<org.eclipse.core.runtime.IPath>
    getResources(@NonNull org.eclipse.core.runtime.IPath path, @NonNull org.eclipse.core.resources.IProject project)
    Gets a collection of resource paths included in the group.
  • Method Details

    • getID

      @NonNull String getID()
      Gets the unique identifier of the grouping. The grouping ID must be unique.
      Returns:
      the id
    • getPath

      @Nullable org.eclipse.core.runtime.IPath getPath(@NonNull Object group, @NonNull org.eclipse.core.resources.IProject project)
      Gets the path of the grouping object. If the object is not a grouping, returns null. The grouping path must be unique and must not match the path to any project resource.
      Parameters:
      group - the object that is presumably a grouping of this provider for which it is necessary to return the correct unique path
      project - of the project
      Returns:
      the path of this group, or null if the object is not a grouping
    • getParent

      @Nullable org.eclipse.core.runtime.IPath getParent(@NonNull org.eclipse.core.runtime.IPath path, @NonNull org.eclipse.core.resources.IProject project)
      Gets the parent path for the resource or group path.
      Parameters:
      path - the relative path of this resource with respect to its project for the resource or group path
      project - the project
      Returns:
      the path of the parent of this path, or null if the object is root
    • getParents

      @NonNull Collection<org.eclipse.core.runtime.IPath> getParents(@NonNull org.eclipse.core.runtime.IPath path, @NonNull org.eclipse.core.resources.IProject project)
      Gets a collection of parent paths along the object path.
      Parameters:
      path - the the relative path of this resource with respect to its project for the resource or a group whose parent paths need to be returned
      project - the project
      Returns:
      the groups, or empty collection, if the collection is empty then the object is root
    • getResources

      @NonNull Collection<org.eclipse.core.runtime.IPath> getResources(@NonNull org.eclipse.core.runtime.IPath path, @NonNull org.eclipse.core.resources.IProject project)
      Gets a collection of resource paths included in the group.
      Parameters:
      path - the path to a group
      project - the project
      Returns:
      the resources, or empty collection if group has no resources