Interface IMetadataRepository

    • Method Detail

      • addInstallableUnits

        void addInstallableUnits​(Collection<IInstallableUnit> installableUnits)
        Add the given installable units to this repository.
        installableUnits - the installable units to add
      • addReferences

        void addReferences​(Collection<? extends IRepositoryReference> references)

        Adds references to another repository to this repository. When a repository is loaded by IMetadataRepositoryManager, its references are automatically added to the repository manager's set of known repositories.

        Note that this method does not add the contents of the given repositories to this repository, but merely adds the location of other repositories to the metadata of this repository.

        references - The references to add
      • getReferences

        Collection<IRepositoryReference> getReferences()
        Returns the repositories that this repository is referencing.
        An immutable collection of repository references, possibly empty but never null.
      • removeInstallableUnits

        boolean removeInstallableUnits​(Collection<IInstallableUnit> installableUnits)
        Removes all installable units in the given collection from this repository.
        installableUnits - the installable units to remove
        true if any units were actually removed, and false otherwise
      • removeAll

        void removeAll()
        Remove all installable units from this repository.
      • executeBatch

        IStatus executeBatch​(IRunnableWithProgress runnable,
                             IProgressMonitor monitor)
        Executes a runnable against this repository. It is up to the repository implementor to determine what "batch process" means, for example, it may mean that the repository index is not stored until after the runnable completes. The runnable should not execute anything in a separate thread.
        runnable - The runnable to execute
        monitor - A progress monitor that will be passed to the runnable
        The result of running the runnable. Any exceptions thrown during the execution will be returned in the status.
      • compress

        void compress​(IPool<IInstallableUnit> iuPool)
        Cause semantically equivalent IInstallableUnits in the receiver to be replaced with a shared object from the provided IPool. New objects are added to the IPool as required.

        While the IPool should be retained to increase the scope of sharing when calling compress(IPool) on subsequent repositories, the IPool can be discarded without adversely effecting the receiver.