Class ContentProviderMap
Data class for storing content providers, use IContentProviderManager to access the global instance of this class
Inheritance
Inherited Members
Namespace: EPiServer.Core
Assembly: EPiServer.dll
Version: 10.10.4Syntax
[ServiceConfiguration]
public class ContentProviderMapConstructors
ContentProviderMap()
Initializes a new instance of the ContentProviderMap class initialized with specified providers.
Declaration
public ContentProviderMap()ContentProviderMap(PermanentContentLinkMapper)
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Initializes a new instance of the ContentProviderMap class initialized with specified providers.
Declaration
[Obsolete("Use default parameter-less constructor, class no longer have dependencies on external implementations")]
public ContentProviderMap(PermanentContentLinkMapper pageLinkMapStore)Parameters
| Type | Name | Description | 
|---|---|---|
| PermanentContentLinkMapper | pageLinkMapStore | The link mapper. | 
ContentProviderMap(PermanentContentLinkMapper, IServiceLocator)
Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Initializes a new instance of the ContentProviderMap class initialized with specified providers.
Declaration
[Obsolete("Use default parameter-less constructor, class no longer have dependencies on external implementations")]
public ContentProviderMap(PermanentContentLinkMapper pageLinkMapStore, IServiceLocator serviceLocator)Parameters
| Type | Name | Description | 
|---|---|---|
| PermanentContentLinkMapper | pageLinkMapStore | The link mapper. | 
| IServiceLocator | serviceLocator | The service locator to use | 
Properties
CustomProvidersExist
Gets a value indicating whether there exist other providers than Default provider
Declaration
public virtual bool CustomProvidersExist { get; }Property Value
| Type | Description | 
|---|---|
| System.Boolean | 
 | 
Methods
AddProvider(ContentProvider)
Adds a content provider including entry points for the content provider to the map.
Declaration
public virtual void AddProvider(ContentProvider provider)Parameters
| Type | Name | Description | 
|---|---|---|
| ContentProvider | provider | The content provider. | 
GetDefaultProvider()
Gets the default provider, that is the provider that is registered with key String.Empty.
Declaration
public virtual ContentProvider GetDefaultProvider()Returns
| Type | Description | 
|---|---|
| ContentProvider | Default content provider | 
GetProvider(ContentReference)
Gets the content provider that serves the content specified by the given content reference
Declaration
public virtual ContentProvider GetProvider(ContentReference contentLink)Parameters
| Type | Name | Description | 
|---|---|---|
| ContentReference | contentLink | The content link. | 
Returns
| Type | Description | 
|---|---|
| ContentProvider | 
GetProvider(String)
Gets the content provider instance registered with given id.
Declaration
public virtual ContentProvider GetProvider(string providerId)Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | providerId | The provider id. | 
Returns
| Type | Description | 
|---|---|
| ContentProvider | The content provider registered with the given id | 
Initialize(ProviderSettingsCollection)
Initializes the provider map with the given data factory and builds up the page providers.
Declaration
[Obsolete("Initialization is not part of this class anymore, either add providers programmatically using AddProvider or initialize CMS", true)]
public void Initialize(ProviderSettingsCollection contentProviders)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Configuration.ProviderSettingsCollection | contentProviders | The page provider configuration. | 
IsEntryPoint(ContentReference)
Determines whether the specified contentLink is registered as an entrypoint
Declaration
public virtual bool IsEntryPoint(ContentReference contentLink)Parameters
| Type | Name | Description | 
|---|---|---|
| ContentReference | contentLink | The content link. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | 
 | 
Iterate(Action<ContentProvider>)
Method that let passed in delegate operate on each registered content provider
Declaration
public void Iterate(Action<ContentProvider> contentProviderHandler)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Action<ContentProvider> | contentProviderHandler | The content provider handler. | 
Iterate(Func<ContentProvider, Boolean>)
Method that let passed in delegate operate on each registered content provider
Declaration
public void Iterate(Func<ContentProvider, bool> contentProviderFunction)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Func<ContentProvider, System.Boolean> | contentProviderFunction | The delegate function called for each provider. If function returns true the iteration is stopped. | 
RemoveProvider(String)
Remove any loaded ContentProvider
Declaration
public virtual bool RemoveProvider(string providerName)Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | providerName | Name of the provider. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | True if remove succeded | 
