November Happy Hour will be moved to Thursday December 5th.

Class DefaultContentVersionRepository

Unsupported INTERNAL API! Not covered by semantic versioning; might change without notice.

Inheritance
System.Object
DefaultContentVersionRepository
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.DataAbstraction
Assembly: EPiServer.dll
Version: 9.12.2
Syntax
[ServiceConfiguration]
public class DefaultContentVersionRepository : IContentVersionRepository

Constructors

DefaultContentVersionRepository()

Declaration
public DefaultContentVersionRepository()

Fields

CachedContentVersionKey

Declaration
public const string CachedContentVersionKey = "EP:ContentVersion:"
Field Value
Type Description
System.String

Methods

ClearCache(ContentReference)

Declaration
public void ClearCache(ContentReference contentLink)
Parameters
Type Name Description
ContentReference contentLink

Delete(ContentReference)

Delete a single version of a Content

Declaration
public virtual void Delete(ContentReference contentLink)
Parameters
Type Name Description
ContentReference contentLink

The content link.

DeleteVersionByDataAccess(ContentReference)

Deletes the version from Respository.

Declaration
protected virtual void DeleteVersionByDataAccess(ContentReference contentLink)
Parameters
Type Name Description
ContentReference contentLink

The content link.

Initialize(IContentEvents)

Declaration
public static void Initialize(IContentEvents contentEvents)
Parameters
Type Name Description
IContentEvents contentEvents

List(ContentReference)

Lists all versions

Declaration
public virtual IEnumerable<ContentVersion> List(ContentReference contentLink)
Parameters
Type Name Description
ContentReference contentLink

The content link.

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

All matching versions

List(ContentReference, String)

Lists all versions for a page current language selection if the languageBranch is null otherwise lists all versions for a page for a specific language

Declaration
public virtual IEnumerable<ContentVersion> List(ContentReference contentLink, string languageBranch)
Parameters
Type Name Description
ContentReference contentLink

The content link.

System.String languageBranch

The language branch

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

All matching versions

ListByDataAccess(ContentReference)

Read ContentVersions from repository.

Declaration
protected virtual IEnumerable<ContentVersion> ListByDataAccess(ContentReference contentLink)
Parameters
Type Name Description
ContentReference contentLink

The content link.

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

ListDelayedPublish()

Lists all contents that are set to delayed publish.

Declaration
public virtual IEnumerable<ContentReference> ListDelayedPublish()
Returns
Type Description
System.Collections.Generic.IEnumerable<ContentReference>

matching contents

ListPublished(ContentReference)

Lists the published versions for a content

Declaration
public virtual IEnumerable<ContentVersion> ListPublished(ContentReference contentLink)
Parameters
Type Name Description
ContentReference contentLink

The content link.

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

All published versions for the content

Load(ContentReference)

Loads the version.

Declaration
public virtual ContentVersion Load(ContentReference contentLink)
Parameters
Type Name Description
ContentReference contentLink

The content link.

Returns
Type Description
ContentVersion

A ContentVersion

LoadCommonDraft(ContentReference, String)

Loads the common draft.

Declaration
public virtual ContentVersion LoadCommonDraft(ContentReference contentLink, string language)
Parameters
Type Name Description
ContentReference contentLink

The content link to load common draft for.

System.String language

The language.

Returns
Type Description
ContentVersion

CommonDraft if it exist, otherwise Published, If no published exist the latest saved version is returned

LoadPublished(ContentReference)

Loads the published version

Declaration
public virtual ContentVersion LoadPublished(ContentReference contentLink)
Parameters
Type Name Description
ContentReference contentLink

The content link.

Returns
Type Description
ContentVersion

A ContentVersion

LoadPublished(ContentReference, String)

Loads the published version a page with current language selection if the languageBranch is null otherwise loads the published version a page for a specific language

Declaration
public virtual ContentVersion LoadPublished(ContentReference contentLink, string languageBranch)
Parameters
Type Name Description
ContentReference contentLink

The content link.

System.String languageBranch

The language branch.

Returns
Type Description
ContentVersion

A ContentVersion

SetCommonDraft(ContentReference)

Sets the specified version as common draft.

Declaration
public void SetCommonDraft(ContentReference contentLink)
Parameters
Type Name Description
ContentReference contentLink

The content link.

Implements

Extension Methods