org.eclipse.ease.ui.completion.provider

## Class JavaPackagesCompletionProvider

- java.lang.Object
- - org.eclipse.ease.ui.completion.AbstractCompletionProvider
  - - org.eclipse.ease.ui.completion.provider.JavaPackagesCompletionProvider

All Implemented Interfaces:
  ICompletionProvider

    public class JavaPackagesCompletionProvider
    extends AbstractCompletionProvider

### Field Summary

### Fields inherited from interface org.eclipse.ease.ui.completion.ICompletionProvider

`TRACE_CODE_COMPLETION`

### Constructor Summary

Constructors
Constructor and Description
`JavaPackagesCompletionProvider()`

### Method Summary

All Methods Static Methods Instance Methods Concrete Methods
`static boolean` `containsPackage(String candidate)` Try to find a package in the registered package list
`static Collection<String>` `getExportedPackages(org.osgi.framework.Bundle bundle)` Get a list of all exported packages of a bundle.
`static Map<String,Collection<String>>` `getPackages()`
`boolean` `isActive(ICompletionContext context)` Query indicating that this providers completion proposals should be taken into account.

### Methods inherited from class org.eclipse.ease.ui.completion.AbstractCompletionProvider

`getContext, getProposals`

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

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

### Constructor Detail

#### JavaPackagesCompletionProvider

    public JavaPackagesCompletionProvider()

### Method Detail

#### isActive

    public boolean isActive(ICompletionContext context)

Description copied from interface: `ICompletionProvider`
Query indicating that this providers completion proposals should be taken into account.

Specified by:
  `isActive` in interface `ICompletionProvider`
Overrides:
  `isActive` in class `AbstractCompletionProvider`
Parameters:
  `context` - `ICompletionContext` with necessary information to calculate proposals.
Returns:
  `true` when active

#### getPackages

    public static Map<String,Collection<String>> getPackages()

#### getExportedPackages

    public static Collection<String> getExportedPackages(org.osgi.framework.Bundle bundle)

Get a list of all exported packages of a bundle.

Parameters:
  `bundle` - bundle instance
Returns:
  collection of exported packages

#### containsPackage

    public static boolean containsPackage(String candidate)

Try to find a package in the registered package list

Parameters:
  `candidate` - package name to look up
Returns:
  `true` when package is registered