Class AuditedEntity
- Namespace
- Dynamicweb.Core
- Assembly
- Dynamicweb.Core.dll
The AuditedEntity class holds information about a given entity and when and by who it was audited
[Serializable]
public class AuditedEntity
- Inheritance
-
AuditedEntity
- Inherited Members
Constructors
AuditedEntity(DateTime, DateTime)
Initializes a new instance of the AuditedEntity class.
public AuditedEntity(DateTime created, DateTime updated)
Parameters
AuditedEntity(DateTime, string)
Initializes a new instance of the AuditedEntity class.
public AuditedEntity(DateTime created, string createdBy)
Parameters
created
DateTime- The created date and time.
createdBy
string- The user id of the user who created the entity.
AuditedEntity(DateTime, string, DateTime, string)
Initializes a new instance of the AuditedEntity class.
public AuditedEntity(DateTime created, string createdBy, DateTime updated, string updatedBy)
Parameters
created
DateTime- The created date and time.
createdBy
string- The user id of the user who created the entity.
updated
DateTime- The updated date and time.
updatedBy
string- The user id of the user who last updated the entity.
AuditedEntity(DateTime, string, string, DateTime, string, string)
Initializes a new instance of the AuditedEntity class.
[Obsolete("Use AuditedEntity(DateTime created, string createdBy, DateTime updated, string updatedBy) instead.")]
public AuditedEntity(DateTime created, string createdBy, string createdByName, DateTime updated, string updatedBy, string updatedByName)
Parameters
created
DateTime- The created date and time.
createdBy
string- The user id of the user who created the entity.
createdByName
string- Name of the user created the entity.
updated
DateTime- The updated date and time.
updatedBy
string- The user id of the user who last updated the entity.
updatedByName
string- Name of the user who last updated the entity.
Properties
CreatedAt
Gets the created date and time.
public DateTime CreatedAt { get; }
Property Value
CreatedBy
Gets the user id of the user who created the entity.
public string CreatedBy { get; }
Property Value
CreatedByName
Gets the name of the user who created the entity.
[Obsolete("Do not use - use extension method from Dynamicweb.Security.AuditExtensions")]
public string CreatedByName { get; }
Property Value
LastModifiedAt
Gets the last modified date and time.
public DateTime LastModifiedAt { get; }
Property Value
LastModifiedBy
Gets the last modified by date and time.
public string LastModifiedBy { get; }
Property Value
LastModifiedByName
Gets the name of user who last modified the entity.
[Obsolete("Do not use - use extension method from Dynamicweb.Security.AuditExtensions")]
public string LastModifiedByName { get; }
Property Value
Methods
MarkAsUpdated()
Marks as updated.
public AuditedEntity MarkAsUpdated()
Returns
- AuditedEntity
- AuditedEntity.
MarkAsUpdated(string)
Marks the entity as updated.
public AuditedEntity MarkAsUpdated(string updatedBy)
Parameters
updatedBy
string- The user id of the user who updated the entity.
Returns
- AuditedEntity
- AuditedEntity.