Try our conversational search powered by Generative AI!

Class ContentActivity

An activity related to content changes made in the system.

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.Activities
Assembly: EPiServer.dll
Version: 11.20.7
Syntax
public class ContentActivity : Activity

Constructors

ContentActivity(ContentReference, CultureInfo, Guid, Int32, String, String)

Initializes a new instance of the ContentActivity class.

Declaration
public ContentActivity(ContentReference contentLink, CultureInfo language, Guid contentGuid, int contentTypeId, string name, string changedBy)
Parameters
Type Name Description
ContentReference contentLink

The content reference of the content that the activity is related to.

System.Globalization.CultureInfo language

The language of the content that the activity is related to.

System.Guid contentGuid

The unique identifier of the content that the activity is related to.

System.Int32 contentTypeId

The content type of the content that the activity is related to.

System.String name

The name of the content that the activity is related to.

System.String changedBy

The username of the user responsible for the change recorded by the activity.

ContentActivity(ContentReference, Guid, Int32, String, String)

Initializes a new instance of the ContentActivity class.

Declaration
public ContentActivity(ContentReference contentLink, Guid contentGuid, int contentTypeId, string name, string changedBy)
Parameters
Type Name Description
ContentReference contentLink

The content reference of the content that the activity is related to.

System.Guid contentGuid

The unique identifier of the content that the activity is related to.

System.Int32 contentTypeId

The content type of the content that the activity is related to.

System.String name

The name of the content that the activity is related to.

System.String changedBy

The username of the user responsible for the change recorded by the activity.

ContentActivity(ContentActionType, ContentReference, CultureInfo, Guid, Int32, String, String)

Initializes a new instance of the ContentActivity class.

Declaration
public ContentActivity(ContentActionType contentAction, ContentReference contentLink, CultureInfo language, Guid contentGuid, int contentTypeId, string name, string changedBy)
Parameters
Type Name Description
ContentActionType contentAction

The content action that has taken place.

ContentReference contentLink

The content reference of the content that the activity is related to.

System.Globalization.CultureInfo language

The language of the content that the activity is related to.

System.Guid contentGuid

The unique identifier of the content that the activity is related to.

System.Int32 contentTypeId

The content type of the content that the activity is related to.

System.String name

The name of the content that the activity is related to.

System.String changedBy

The username of the user responsible for the change recorded by the activity.

ContentActivity(ContentActionType, ContentReference, Guid, Int32, String, String)

Initializes a new instance of the ContentActivity class.

Declaration
public ContentActivity(ContentActionType contentAction, ContentReference contentLink, Guid contentGuid, int contentTypeId, string name, string changedBy)
Parameters
Type Name Description
ContentActionType contentAction

The content action that has taken place.

ContentReference contentLink

The content reference of the content that the activity is related to.

System.Guid contentGuid

The unique identifier of the content that the activity is related to.

System.Int32 contentTypeId

The content type of the content that the activity is related to.

System.String name

The name of the content that the activity is related to.

System.String changedBy

The username of the user responsible for the change recorded by the activity.

Fields

DefaultProvider

Declaration
public const string DefaultProvider = "default"
Field Value
Type Description
System.String

UriScheme

Declaration
public const string UriScheme = "content"
Field Value
Type Description
System.String

Properties

ActionType

Returns which type of action this activity instance corresponds to.

Declaration
public virtual ContentActionType ActionType { get; }
Property Value
Type Description
ContentActionType

ContentGuid

Gets the unique identifier of the related content.

Declaration
public virtual Guid ContentGuid { get; }
Property Value
Type Description
System.Guid

The ContentReference of the related content

Declaration
public virtual ContentReference ContentLink { get; }
Property Value
Type Description
ContentReference

ContentTypeId

Gets the content type identifier of the related content.

Declaration
public virtual int ContentTypeId { get; }
Property Value
Type Description
System.Int32

Language

Gets the language of the related content.

Declaration
public virtual CultureInfo Language { get; }
Property Value
Type Description
System.Globalization.CultureInfo

Name

Gets the name of the related content.

Declaration
public string Name { get; set; }
Property Value
Type Description
System.String
Remarks

This is the name when the activity was recorded and may be different from the current name of the content.

RelatedItem

Gets or sets the item this Activity is related to.

Declaration
protected override Uri RelatedItem { get; set; }
Property Value
Type Description
System.Uri
Overrides
Remarks

For content activities like publish it will be the content version. For project items like "item added to project" it will be project. For messages it will dependend on the type of message.

Extension Methods