Class PageStoreBase
The base class that defines the events for page providers / DataFactory.
Inherited Members
Namespace: EPiServer.Core
Assembly: EPiServer.dll
Version: 7.19.2Syntax
public class PageStoreBase : IContentEvents, IDisposableConstructors
PageStoreBase()
Default constructor.
Declaration
public PageStoreBase()Remarks
This is only meant to be used in test scenarios.
Methods
CreateSaveEventArgs(IContent, SaveAction, AccessLevel)
Creates an instance of SavePageEventArgs.
Declaration
protected SaveContentEventArgs CreateSaveEventArgs(IContent content, SaveAction action, AccessLevel access)Parameters
| Type | Name | Description | 
|---|---|---|
| IContent | content | The content to save. | 
| SaveAction | action | The requested save action. | 
| AccessLevel | access | The required access level. | 
Returns
| Type | Description | 
|---|---|
| SaveContentEventArgs | A fully initialized SavePageEventArgs instance. | 
Dispose()
Implemenation of System.IDisposable
Declaration
public void Dispose()Dispose(Boolean)
Actual implementation of Dispose.
Declaration
protected virtual void Dispose(bool disposing)Parameters
| Type | Name | Description | 
|---|---|---|
| System.Boolean | disposing | 
RaiseCancellableDeleteEvent(String, String, DeleteContentEventArgs)
Raises a cancellable delete event.
Declaration
protected void RaiseCancellableDeleteEvent(string key, string defaultReason, DeleteContentEventArgs eventArgs)Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | key | The event identifier. | 
| System.String | defaultReason | The default cancel reason. | 
| DeleteContentEventArgs | eventArgs | The DeleteContentEventArgs instance containing the event data. | 
Remarks
If the events is cancelled a EPiServerCancelException is thrown. Unless the cancelling 
handler sets the CancelReason of PageEventArgs, the defaultReason is
used as exception message.
RaiseCancellablePageEvent(String, String, ContentEventArgs)
Raises a cancellable page event.
Declaration
protected void RaiseCancellablePageEvent(string key, string defaultReason, ContentEventArgs eventArgs)Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | key | The event identifier. | 
| System.String | defaultReason | The default cancel reason. | 
| ContentEventArgs | eventArgs | The PageEventArgs instance containing the event data. | 
Remarks
If the events is cancelled a EPiServerCancelException is thrown. Unless the cancelling 
handler sets the CancelReason of PageEventArgs, the defaultReason is
used as exception message.
RaiseChildrenEvent(String, ChildrenEventArgs)
Raises a page children event.
Declaration
protected bool RaiseChildrenEvent(string key, ChildrenEventArgs eventArgs)Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | key | The event identifier. | 
| ChildrenEventArgs | eventArgs | The ChildrenEventArgs instance containing the event data. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | True if the event did not cancel. | 
RaiseDeleteEvent(String, DeleteContentEventArgs)
Raises the specified delete event.
Declaration
protected bool RaiseDeleteEvent(string key, DeleteContentEventArgs eventArgs)Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | key | The event identifier. | 
| DeleteContentEventArgs | eventArgs | The DeleteContentEventArgs instance containing the event data. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | True if the event did not cancel. | 
RaisePageEvent(String, ContentEventArgs)
Raises the specified page event.
Declaration
protected bool RaisePageEvent(string key, ContentEventArgs eventArgs)Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | key | The event identifier. | 
| ContentEventArgs | eventArgs | The ContentEventArgs instance containing the event data. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | True if the event did not cancel. | 
RaisePageEvent(String, IList<PageReference>, ContentEventArgs)
Raises the specified page event for the passed page links.
Declaration
[Obsolete("This method is not used anymore, it was used in pre 7 versions.")]
protected bool RaisePageEvent(string key, IList<PageReference> pageLinks, ContentEventArgs eventArgs)Parameters
| Type | Name | Description | 
|---|---|---|
| System.String | key | The event identifier. | 
| System.Collections.Generic.IList<PageReference> | pageLinks | The page links. | 
| ContentEventArgs | eventArgs | The PageEventArgs instance containing the event data. | 
Returns
| Type | Description | 
|---|---|
| System.Boolean | True if no event invocation was cancelled, false otherwise. | 
Events
CheckedInContent
Occurs when a version of a content item has been checked in.
Declaration
public event EventHandler<ContentEventArgs> CheckedInContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
Remarks
This event will be raised after one of the CreatedContent or SavedContent events.
CheckedInPage
Occurs when a version has been checked in
Declaration
public event PageEventHandler CheckedInPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
CheckingInContent
Occurs when a version of a content item is about to be checked in.
Declaration
public event EventHandler<ContentEventArgs> CheckingInContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
Remarks
This event will be raised after one of the CreatingContent or SavingContent events.
CheckingInPage
Occurs when a version is requested to be checked in
Declaration
public event PageEventHandler CheckingInPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
CreatedContent
Occurs when a new content item has been saved to the repository.
Declaration
public event EventHandler<ContentEventArgs> CreatedContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
Remarks
This event will be raised along with the PublishedContent or the CheckedInContent if the content item should be published or checked in while created.
CreatedPage
Occurs when a new page is created
Declaration
public event PageEventHandler CreatedPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
CreatingContent
Occurs when a new content item is about to be saved to the repository.
Declaration
public event EventHandler<ContentEventArgs> CreatingContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
Remarks
This event will be raised along with the PublishingContent or the CheckingInContent if the content item should be published or checked in while created.
CreatingPage
Occurs when a page is requested to be created
Declaration
public event PageEventHandler CreatingPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
DeletedContent
Occurs when a content item has been deleted from the wastebasket.
Declaration
public event EventHandler<DeleteContentEventArgs> DeletedContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<DeleteContentEventArgs> | 
Remarks
Note that this event is not raised when a content item is moved to the wastebasket. At that point only the MovedContent event is raised.
DeletedContentLanguage
Occurs when a language branch of a content item has been deleted.
Declaration
public event EventHandler<ContentEventArgs> DeletedContentLanguageEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
DeletedContentVersion
Occurs when a content item version has been deleted.
Declaration
public event EventHandler<ContentEventArgs> DeletedContentVersionEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
DeletedPage
Occurs when a page has been deleted
Declaration
public event PageEventHandler DeletedPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
DeletedPageLanguage
Occurs when a language branch of a page has been deleted
Declaration
public event PageEventHandler DeletedPageLanguageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
DeletingContent
Occurs when a content item is about to be deleted permanently.
Declaration
public event EventHandler<DeleteContentEventArgs> DeletingContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<DeleteContentEventArgs> | 
Remarks
Note that this event is not raised when a content item is about to be moved to the wastebasket. At that point only the MovingContent event is raised.
DeletingContentLanguage
Occurs when a language branch of a content item is about to be deleted.
Declaration
public event EventHandler<ContentEventArgs> DeletingContentLanguageEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
DeletingContentVersion
Occurs when a content item version is about to be deleted permanently.
Declaration
public event EventHandler<ContentEventArgs> DeletingContentVersionEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
DeletingPage
Occurs when a page is requested to be deleted
Declaration
public event PageEventHandler DeletingPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
DeletingPageLanguage
Occurs when a language branch of a page is requested to be deleted
Declaration
public event PageEventHandler DeletingPageLanguageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
FailedLoadingChildren
Occurs when a page list failed for some reason.
Declaration
public event ChildrenEventHandler FailedLoadingChildrenEvent Type
| Type | Description | 
|---|---|
| ChildrenEventHandler | 
Remarks
This event is generated if a LoadingChildrem is NOT followed by a LoadedChildren, i e FailedLoadingChildren is called instead of LoadedChildren. This is typically used if you need to clean up something that was initiated by LoadingChildren.
FailedLoadingContent
Occurs when an exception was raised while a content item was loaded from the repository.
Declaration
public event EventHandler<ContentEventArgs> FailedLoadingContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
Remarks
This event is raised if a LoadingContent is NOT followed by a LoadedContent, i e FailedLoadingContent is called instead of LoadedContent. This is typically used if you need to clean up something that was initiated by LoadingContent.
FailedLoadingPage
Occurs when a page load failed for some reason.
Declaration
public event PageEventHandler FailedLoadingPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
Remarks
This event is generated if a LoadingPage is NOT followed by a LoadedPage, i e FailedLoadingPage is called instead of LoadedPage. This is typically used if you need to clean up something that was initiated by LoadingPage.
FinishedLoadingChildren
Occurs when a list has been loaded from GetChildren
Declaration
public event ChildrenEventHandler FinishedLoadingChildrenEvent Type
| Type | Description | 
|---|---|
| ChildrenEventHandler | 
Remarks
This event is triggered after loading dynamic and personalized data.
FinishedLoadingPage
Occurs when a page is loaded through GetPage
Declaration
public event PageEventHandler FinishedLoadingPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
Remarks
This event is triggered after loading dynamic and personalized data.
LoadedChildren
Occurs when a list has been loaded from GetChildren
Declaration
public event ChildrenEventHandler LoadedChildrenEvent Type
| Type | Description | 
|---|---|
| ChildrenEventHandler | 
Remarks
This event is triggered before loading dynamic and personalized data.
LoadedContent
Occurs when a content item has been loaded from the repository.
Declaration
public event EventHandler<ContentEventArgs> LoadedContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
LoadedDefaultContent
Occurs when a new content item has been created and initalized through the GetDefaultContent method.
Declaration
public event EventHandler<ContentEventArgs> LoadedDefaultContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
LoadedDefaultPageData
Occurs when a empty page is loaded through GetDefaultPageData
Declaration
public event PageEventHandler LoadedDefaultPageDataEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
LoadedPage
Occurs when a page is loaded through GetPage
Declaration
public event PageEventHandler LoadedPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
Remarks
This event is triggered before loading dynamic and personalized data.
LoadingChildren
Occurs when a list is requested from GetChildren
Declaration
public event ChildrenEventHandler LoadingChildrenEvent Type
| Type | Description | 
|---|---|
| ChildrenEventHandler | 
LoadingContent
Occurs when a content item are about to be loaded from the repository.
Declaration
public event EventHandler<ContentEventArgs> LoadingContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
LoadingDefaultContent
Occurs when a new content item is about to be created and initalized through the GetDefaultContent method.
Declaration
public event EventHandler<ContentEventArgs> LoadingDefaultContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
LoadingDefaultPageData
Occurs when a empty page is requested through GetDefaultPageData
Declaration
public event PageEventHandler LoadingDefaultPageDataEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
LoadingPage
Occurs when a page is requested through GetPage
Declaration
public event PageEventHandler LoadingPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
MovedContent
Occurs when a content item has been moved from one location to another.
Declaration
public event EventHandler<ContentEventArgs> MovedContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
Remarks
Note that this event is also raised when a content item is moved to the wastebasket.
MovedPage
Occurs when a page has been moved
Declaration
public event PageEventHandler MovedPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
MovingContent
Occurs when a content item is about to be moved from one location to another.
Declaration
public event EventHandler<ContentEventArgs> MovingContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
Remarks
Note that this event is also raised when a content item is about to be moved to the wastebasket.
MovingPage
Occurs when a page is requested to be moved
Declaration
public event PageEventHandler MovingPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
PublishedContent
Occurs when a content item or a version of a content item has been published.
Declaration
public event EventHandler<ContentEventArgs> PublishedContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
Remarks
This event will be raised after one of the CreatedContent or SavedContent events.
PublishedPage
Occurs when a page/version has been published
Declaration
public event PageEventHandler PublishedPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
PublishingContent
Occurs when a content item or a version of a content item is requested to be published.
Declaration
public event EventHandler<ContentEventArgs> PublishingContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
Remarks
This event will be raised after one of the CreatingContent or SavingContent events.
PublishingPage
Occurs when a page/version is requested to be published
Declaration
public event PageEventHandler PublishingPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
SavedContent
Occurs when an existing content item has been saved to the repository.
Declaration
public event EventHandler<ContentEventArgs> SavedContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
Remarks
This event will be raised along with the PublishedContent or the CheckedInContent if the content item should be published or checked in while saved.
SavedPage
Occurs when a existing page is modified and saved
Declaration
public event PageEventHandler SavedPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
SavingContent
Occurs when an existing content item is about to be saved to the repository.
Declaration
public event EventHandler<ContentEventArgs> SavingContentEvent Type
| Type | Description | 
|---|---|
| System.EventHandler<ContentEventArgs> | 
Remarks
This event will be raised along with the PublishingContent or the CheckingInContent if the content item should be published or checked in while saved.
SavingPage
Occurs when a existing page is modified and saved
Declaration
public event PageEventHandler SavingPageEvent Type
| Type | Description | 
|---|---|
| PageEventHandler | 
