Class ChangeRecord
Represents a change or a set of changes that has been done to a record or entity within a single operation.
Inherited Members
Namespace: Nevatech.Vsb.Repository.Entities
Assembly: Nevatech.Vsb.Repository.dll
Syntax
[DataContract(Namespace = "http://schemas.nevatech.com/sentinet/2011/02")]
public class ChangeRecord : IValidator, IExtensibleDataObject
Constructors
ChangeRecord()
Initializes an empty instance.
Declaration
public ChangeRecord()
ChangeRecord(ChangeRecord, bool)
Initializes new instance from provided record.
Declaration
public ChangeRecord(ChangeRecord record, bool exactCopy)
Parameters
| Type | Name | Description |
|---|---|---|
| ChangeRecord | record | Record to be initialized from. |
| bool | exactCopy | Flag indicating that all properties including user information must be copied. |
Properties
ChangeSetId
Gets or sets the identifier of the changeset containing this change.
Declaration
[DataMember]
public int ChangeSetId { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
ChangeType
Gets or sets the type of the change that has been made to the entity.
Declaration
[DataMember]
public ChangeTypes ChangeType { get; set; }
Property Value
| Type | Description |
|---|---|
| ChangeTypes |
Created
Gets the date and time when modification(s) were done.
Declaration
[DataMember]
public DateTime Created { get; }
Property Value
| Type | Description |
|---|---|
| DateTime |
EntityId
Gets or sets the identifier of the entity that has been modified.
Declaration
[DataMember]
public int EntityId { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
EntityName
Gets or sets the friendly description of the entity that has been modified.
Declaration
[DataMember]
public string EntityName { get; set; }
Property Value
| Type | Description |
|---|---|
| string |
EntityType
Gets or sets the type of the entity that has been modified.
Declaration
[DataMember]
public EntityType EntityType { get; set; }
Property Value
| Type | Description |
|---|---|
| EntityType |
ErrorMessage
Gets the summary of validation errors populated by the call to Validate() method.
Declaration
public string ErrorMessage { get; }
Property Value
| Type | Description |
|---|---|
| string |
ExtensionData
Gets or sets ExtensionDataObject that enables serialization roundtrips.
Declaration
public ExtensionDataObject ExtensionData { get; set; }
Property Value
| Type | Description |
|---|---|
| ExtensionDataObject |
Id
Gets or sets the change identifier.
Declaration
[DataMember]
public int Id { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
IdentityName
Gets the name of identity that was used to authenticate the user.
Declaration
[DataMember(EmitDefaultValue = false)]
public string IdentityName { get; }
Property Value
| Type | Description |
|---|---|
| string |
MajorEntityId
Gets or sets the identifier of the major entity containing this (minor) entity. If this is a major entity itself then EntityId and MajorEntityId are the same.
Declaration
[DataMember]
public int MajorEntityId { get; set; }
Property Value
| Type | Description |
|---|---|
| int |
MajorEntityName
Gets the friendly name of the major entity containing this entity.
Declaration
[DataMember]
public string MajorEntityName { get; }
Property Value
| Type | Description |
|---|---|
| string |
MajorEntityType
Gets or sets the type of the major entity containing this (minor) entity. If this is a major entity itself then EntityType and MajorEntityType are the same.
Declaration
[DataMember]
public EntityType MajorEntityType { get; set; }
Property Value
| Type | Description |
|---|---|
| EntityType |
UserId
Gets the identifier of the user who made the change. Identifier can be Null for system-initiated changes.
Declaration
[DataMember(EmitDefaultValue = false)]
public int? UserId { get; }
Property Value
| Type | Description |
|---|---|
| int? |
UserName
Gets the full name of the user who made the change.
Declaration
[DataMember(EmitDefaultValue = false)]
public string UserName { get; }
Property Value
| Type | Description |
|---|---|
| string |
Methods
Validate()
Evaluates the state of this object.
Declaration
public bool Validate()
Returns
| Type | Description |
|---|---|
| bool | True if state is valid; otherwise, false. |