Class ContentSaveDB

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Handles all database modification of page data.

Inheritance
System.Object
ContentSaveDB
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: EPiServer.DataAccess.Internal
Assembly: EPiServer.dll
Version: 11.20.1
Syntax
[ServiceConfiguration(typeof(ContentSaveDB), Lifecycle = ServiceInstanceScope.Singleton)]
public class ContentSaveDB : ContentDB

Constructors

ContentSaveDB(ServiceAccessor<IDatabaseExecutor>, IContentTypeRepository, IPermanentLinkMapper, ILanguageBranchRepository, IPropertyDefinitionRepository, IPropertyDefinitionTypeRepository, IPropertyDataFactory, IContentFactory, DefaultContentVersionRepository, ServiceAccessor<CategoryDB>, IBlobFactory, PropertyValueConverterFactory, DatabaseDateTimeHandler, IContentVersionResolver, IStatusTransitionEvaluator, ITimeProvider, IPropertyBlockBuilder)

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. This member supports the EPiServer infrastructure and is not intended to be used directly from your code.

Declaration
public ContentSaveDB(ServiceAccessor<IDatabaseExecutor> databaseHandlerAccessor, IContentTypeRepository contentTypeRepository, IPermanentLinkMapper permanentLinkMapper, ILanguageBranchRepository languageBranchRepository, IPropertyDefinitionRepository propertyDefinitionRepository, IPropertyDefinitionTypeRepository propertyDefinitionTypeRepsoitory, IPropertyDataFactory propertyDataFactory, IContentFactory contentFactory, DefaultContentVersionRepository contentVersionRepository, ServiceAccessor<CategoryDB> categoryDataAccess, IBlobFactory blobFactory, PropertyValueConverterFactory propertyValueConverterFactory, DatabaseDateTimeHandler dateTimeHandler, IContentVersionResolver contentVersionResolver, IStatusTransitionEvaluator statusTransitionEvaluator, ITimeProvider timeProvider, IPropertyBlockBuilder propertyBlockBuilder)
Parameters
Type Name Description
ServiceAccessor<IDatabaseExecutor> databaseHandlerAccessor
IContentTypeRepository contentTypeRepository
IPermanentLinkMapper permanentLinkMapper
ILanguageBranchRepository languageBranchRepository
IPropertyDefinitionRepository propertyDefinitionRepository
IPropertyDefinitionTypeRepository propertyDefinitionTypeRepsoitory
IPropertyDataFactory propertyDataFactory
IContentFactory contentFactory
DefaultContentVersionRepository contentVersionRepository
ServiceAccessor<CategoryDB> categoryDataAccess
IBlobFactory blobFactory
PropertyValueConverterFactory propertyValueConverterFactory
DatabaseDateTimeHandler dateTimeHandler
IContentVersionResolver contentVersionResolver
IStatusTransitionEvaluator statusTransitionEvaluator
ITimeProvider timeProvider
IPropertyBlockBuilder propertyBlockBuilder

Fields

UseIChangeTrackingChangedByKey

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. This member supports the EPiServer infrastructure and is not intended to be used directly from your code.

Declaration
public const string UseIChangeTrackingChangedByKey = "PageSaveDB:ChangedBy"
Field Value
Type Description
System.String

UseIChangeTrackingSavedKey

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. This member supports the EPiServer infrastructure and is not intended to be used directly from your code.

Declaration
public const string UseIChangeTrackingSavedKey = "PageSaveDB:PageSaved"
Field Value
Type Description
System.String

Properties

ContentVersionRepository

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Gets or sets the content version repository.

Declaration
protected DefaultContentVersionRepository ContentVersionRepository { get; set; }
Property Value
Type Description
DefaultContentVersionRepository

The content version repository.

UsePageDataChangedBy

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Indicates if the saved by stored in db is taken from PageData instance or set by current user. If true SavedBy property on PageData instance is used else is current user.

Declaration
public static bool UsePageDataChangedBy { get; }
Property Value
Type Description
System.Boolean

UsePageDataSaveTime

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Indicates if the save time stored in db is taken from PageData instance or set by PageSaveDB. If true PageSaved property on PageData instance is used else is time set as DateTime.Now.

Declaration
public static bool UsePageDataSaveTime { get; }
Property Value
Type Description
System.Boolean

Methods

Delete(ContentReference, Boolean)

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Delete content from database

Declaration
public void Delete(ContentReference contentLink, bool forceDelete)
Parameters
Type Name Description
ContentReference contentLink

The link to the content which will be deleted

System.Boolean forceDelete

Delete content even if being linked by other pages

DeleteChildren(ContentReference, Boolean)

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Delete children from database. This member supports the EPiServer infrastructure and is not intended to be used directly from your code.

Declaration
public void DeleteChildren(ContentReference contentLink, bool forceDelete)
Parameters
Type Name Description
ContentReference contentLink

The children of this content will be deleted.

System.Boolean forceDelete

Delete even if referenced by other pages.

DeleteLanguage(ContentReference, String)

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Delete a language branch of a content object This member supports the EPiServer infrastructure and is not intended to be used directly from your code.

Declaration
public void DeleteLanguage(ContentReference contentLink, string languageBranch)
Parameters
Type Name Description
ContentReference contentLink

Link to content for which the language should be deleted

System.String languageBranch

The language branch to delete

Remarks

The published version cannot be deleted

GetReferenceInformationForChildren(ContentReference)

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Gets the reference information for children.

Declaration
public IEnumerable<ReferenceInformation> GetReferenceInformationForChildren(ContentReference contentLink)
Parameters
Type Name Description
ContentReference contentLink

The content link.

Returns
Type Description
System.Collections.Generic.IEnumerable<ReferenceInformation>

GetReferenceInformationForContent(ContentReference, Boolean)

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Gets the content of the reference information for.

Declaration
public IEnumerable<ReferenceInformation> GetReferenceInformationForContent(ContentReference contentLink, bool includeDecendents)
Parameters
Type Name Description
ContentReference contentLink

The content link.

System.Boolean includeDecendents

if set to true [include decendents].

Returns
Type Description
System.Collections.Generic.IEnumerable<ReferenceInformation>

Move(ContentReference, ContentReference)

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Move a content object to another container This member supports the EPiServer infrastructure and is not intended to be used directly from your code.

Declaration
public void Move(ContentReference contentLink, ContentReference destinationLink)
Parameters
Type Name Description
ContentReference contentLink

The link to the content to move

ContentReference destinationLink

The container to which the content will be moved

Move(Int32, Int32, Boolean)

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Move a content object to another container This member supports the EPiServer infrastructure and is not intended to be used directly from your code.

Declaration
public void Move(int contentLinkID, int destinationLinkID, bool archive)
Parameters
Type Name Description
System.Int32 contentLinkID

The link to the content to move

System.Int32 destinationLinkID

The container to which the content will be moved

System.Boolean archive

Set to True if the content is archived.

Remarks

Archiving the content will move it to its Archve page and remove the stop publishing date.

MoveToWastebasket(ContentReference, String)

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Move a content object to the wastebasket This member supports the EPiServer infrastructure and is not intended to be used directly from your code.

Declaration
public void MoveToWastebasket(ContentReference contentLink, string deletedBy)
Parameters
Type Name Description
ContentReference contentLink

The link to the content to move

System.String deletedBy

The deleted by.

Save(IContent, SaveAction, String)

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice. Save page to database This member supports the EPiServer infrastructure and is not intended to be used directly from your code.

Declaration
public virtual ContentReference Save(IContent content, SaveAction action, string currentUser)
Parameters
Type Name Description
IContent content

The content.

SaveAction action

Action that will be performed

System.String currentUser

Name of the user performing this operation

Returns
Type Description
ContentReference
Remarks

If PageLink is empty a new page will be created

Extension Methods