Table of Contents

Class PreviousNameAttribute

Namespace
eQuantic.Core.Data.Modeling
Assembly
eQuantic.Core.Data.Abstractions.dll

The member's previous stored name, so a rename reads as a rename. A model comparison sees only that one name is gone and another has appeared; without this it cannot tell a rename from a member dropped and another added — and on a document store that difference is whether the data survives. Declaring the old name makes the intent explicit and lets the change be generated as a rename, keeping the values.

Name several when a member has been renamed more than once; the comparison accepts any of them.

[AttributeUsage(AttributeTargets.Property, AllowMultiple = true)]
public sealed class PreviousNameAttribute : Attribute
Inheritance
PreviousNameAttribute
Inherited Members

Constructors

PreviousNameAttribute(string)

The member's previous stored name, so a rename reads as a rename. A model comparison sees only that one name is gone and another has appeared; without this it cannot tell a rename from a member dropped and another added — and on a document store that difference is whether the data survives. Declaring the old name makes the intent explicit and lets the change be generated as a rename, keeping the values.

Name several when a member has been renamed more than once; the comparison accepts any of them.

public PreviousNameAttribute(string name)

Parameters

name string

Properties

Name

The stored name this member used to have.

public string Name { get; }

Property Value

string