Interface IEntity
Defines the necessary identifiers and functionality that a class must implement to be usable as an entity
Inherited Members
Namespace: EPiServer.Data.Entity
Assembly: EPiServer.Data.dll
Version: 10.10.4Syntax
public interface IEntity : ICacheable, IReadOnly
Properties
ID
Gets the identifier for the entity. (Unique in the domain of that type).
Declaration
int ID { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
Master
Gets the original instance for a writable copy or null if this is the original instance.
Declaration
object Master { get; }
Property Value
Type | Description |
---|---|
System.Object |
Remarks
This can be used for detecting changes that have been made to a writable copy.
UniqueID
Gets the globally unique identifier for the entity
Declaration
Guid UniqueID { get; }
Property Value
Type | Description |
---|---|
System.Guid |
Methods
CopyAsNew()
Creates a writable copy of the current object that can be saved as a new entity.
Declaration
object CopyAsNew()
Returns
Type | Description |
---|---|
System.Object | A writable copy of the current object. |
Remarks
The cloning is a deep-copy. Identitiers for the entity are cleared.