Overview | Package | Class | Use | Tree | Deprecated | Index
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.eclipse.emf.ecp.core
Interface ECPProjectManager

All Known Implementing Classes:
  ECPProjectManagerImpl

    public interface ECPProjectManager

The ECPProjectManager provides access to ECPProjects and manages their lifecycle. It is available as an OSGi service or using `ECPUtil` It publishes observable events on the `ECPObserverBus`. Related Observer types: `ECPProjectsChangedObserver`, `ECPProjectContentChangedObserver`, `ECPProjectOpenClosedObserver`, `ECPProjectPreDeleteObserver`. Use `ECPUtil#getECPObserverBus()` to retrieve the ObserverBus and `ECPObserverBus#register(ECPObserver)` to register an Observer.

Author:
  Eike Stepper, Jonas, Eugen Neufeld

Method Summary
`ECPProject` | `createProject(ECPProject project, String name)` Method to construct a new Project based on an existing project as template.
`ECPProject` | `createProject(ECPProvider provider, String name)` Method to construct an offline Project, this method calls `createProject(ECPProvider, String, ECPProperties)` with empty properties.
`ECPProject` | `createProject(ECPProvider provider, String name, ECPProperties properties)` Method to construct an offline Project and notify listeners about this add.
`ECPProject` | `createProject(ECPRepository repository, String name, ECPProperties properties)` Method to construct an shared Project, e.g.
`ECPProject` | `getProject(Object adaptable)` Retrieves the project the adaptable belongs to if possible.
`ECPProject` | `getProject(String name)` Searches for a project based on the provided `String`.
`Collection<ECPProject>` | `getProjects()` Returns all known projects.

Method Detail

### createProject

    ECPProject createProject(ECPProvider provider,
                             String name)
                             throws ECPProjectWithNameExistsException

  Method to construct an offline Project, this method calls `createProject(ECPProvider, String, ECPProperties)` with empty properties. If `ECPProvider.hasCreateProjectWithoutRepositorySupport()` returns false an UnsupportedOperationException is thrown.

  Parameters:
    `provider` - the `ECPProvider` of this project
    `name` - the name of the project
  Returns:
    created `ECPProject`
  Throws:
    `ECPProjectWithNameExistsException` - when a project with the same name already exists

### createProject

    ECPProject createProject(ECPProvider provider,
                             String name,
                             ECPProperties properties)
                             throws ECPProjectWithNameExistsException

  Method to construct an offline Project and notify listeners about this add. If `ECPProvider.hasCreateProjectWithoutRepositorySupport()` returns false an UnsupportedOperationException is thrown.

  Parameters:
    `provider` - the `ECPProvider` of this project
    `name` - the name of the project
    `properties` - the project properties
  Returns:
    created `ECPProject`
  Throws:
    `ECPProjectWithNameExistsException` - when a project with the same name already exists

### createProject

    ECPProject createProject(ECPRepository repository,
                             String name,
                             ECPProperties properties)
                             throws ECPProjectWithNameExistsException

  Method to construct an shared Project, e.g. during a checkout, and notify listeners about this add.

  Parameters:
    `repository` - the `ECPRepository` of this project
    `name` - the name of the project
    `properties` - the project properties
  Returns:
    created `ECPProject`
  Throws:
    `ECPProjectWithNameExistsException` - when a project with the same name already exists

### createProject

    ECPProject createProject(ECPProject project,
                             String name)

  Method to construct a new Project based on an existing project as template. If the template project is shared, so is the created project.

  Parameters:
    `project` - the template `ECPProject`
    `name` - the name of the created project
  Returns:
    the clone of the `ECPProject`

### getProject

    ECPProject getProject(Object adaptable)

  Retrieves the project the adaptable belongs to if possible. This method checks whether the adaptable is `ECPProjectAware` and else uses the AdapterUtil to adapt to a project.

  Parameters:
    `adaptable` - the Object to adapt
  Returns:
    the adapted `ECPProject`

### getProject

    ECPProject getProject(String name)

  Searches for a project based on the provided `String`.

  Parameters:
    `name` - of the project to search for
  Returns:
    the `ECPProject`

### getProjects

    Collection<ECPProject> getProjects()

  Returns all known projects.

  Returns:
    an array of all known projects

Overview | Package | Class | Use | Tree | Deprecated | Index
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2015. All Rights Reserved.