# Class RegistryContributor

java.lang.Object
org.eclipse.core.runtime.spi.RegistryContributor

All Implemented Interfaces:
  `IContributor`

public final class RegistryContributor extends Object implements IContributor
This class describes a registry contributor which is an entity that supplies information to the extension registry. Depending on the registry strategy, contributor might delegate some of its functionality to a "host" contributor. For instance, OSGi registry strategy uses "host" contributor to delegate some functionality from fragments to plug-ins.

This class can be instantiated by the registry Service Providers.

This class can be used without OSGi running.

This class can not be extended.

Since:
  org.eclipse.equinox.registry 3.2
Restriction:
  This class is not intended to be subclassed by clients.

## Constructor Summary

Constructors
Constructor
Description
`RegistryContributor(String actualId, String actualName, String hostId, String hostName)`
Constructor for the registry contributor.

## Method Summary

Modifier and Type
Method
Description
`String`
`getActualId()`
Provides actual ID associated with the registry contributor (e.g., "12").
`String`
`getActualName()`
Provides actual name of the registry contributor (e.g., "org.eclipe.core.runtime.fragment").
`String`
`getId()`
Provides ID associated with the entity "in charge" of the contributor (e.g., "1").
`String`
`getName()`
Provides name of the entity "in charge" of the contributor (e.g., "org.eclipse.core.runtime").
`String`
`toString()`

### Methods inherited from class Object

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

## Constructor Details

### RegistryContributor

public RegistryContributor(String actualId, String actualName, String hostId, String hostName)
Constructor for the registry contributor.

The actual ID is a string identifier for the contributor (e.g., "12") and is expected to be unique within the workspace. The actual ID of the contributor must not be `null`.

The actual name is the name associated with the contributor (e.g., "org.eclipse.core.runtime.fragment"). The actual name of the contributor must not be `null`.

The host ID is the identifier associated with the entity "in charge" of the contributor (e.g., "1"). IDs are expected to be unique in the workspace. If contributor does not rely on a host, then `null` should be used as the host ID.

The host name is the name of the entity "in charge" of the contributor (e.g., "org.eclipse.core.runtime"). If contributor does not rely on a host, then `null` should be used as the host name.

There should be 1-to-1 mapping between the contributor and the contibutor ID. The IDs (either actual or host) can not be re-used in the same registry. For example, if ID of 12 was used to identify contributorA, the ID of 12 can not be used to identify contributorB or a host for the contributorC.

Parameters:
  `actualId` - contributor identifier
  `actualName` - name of the contributor
  `hostId` - id associated with the host, or `null`
  `hostName` - name of the host, or `null`

## Method Details

### getActualId

public String getActualId()
Provides actual ID associated with the registry contributor (e.g., "12"). IDs are expected to be unique in the workspace.

Returns:
  actual ID of the registry contributor

### getActualName

public String getActualName()
Provides actual name of the registry contributor (e.g., "org.eclipe.core.runtime.fragment").

Returns:
  actual name of the registry contributor

### getId

public String getId()
Provides ID associated with the entity "in charge" of the contributor (e.g., "1"). IDs are expected to be unique in the workspace. If contributor does not rely on a host, this value should be the same as the actual contributor ID.

Returns:
  id of the registry contributor

### getName

public String getName()
Provides name of the entity "in charge" of the contributor (e.g., "org.eclipse.core.runtime"). If contributor does not rely on a host, this value should be the same as the actual contributor name.

Specified by:
  `getName` in interface `IContributor`
Returns:
  name of the registry contributor

### toString

public String toString()

Overrides:
  `toString` in class `Object`