XPMemberInfo.IsAliased Property
Gets whether a PersistentAliasAttribute attribute is applied to the property.
Namespace: DevExpress.Xpo.Metadata
Assembly: DevExpress.Xpo.v24.1.dll
NuGet Packages: DevExpress.Win.PivotGrid, DevExpress.Win.TreeMap, DevExpress.Xpo
NuGet Package: DevExpress.Xpo
Declaration
Property Value
Type | Description |
---|---|
Boolean | true if the member has the PersistentAliasAttribute attribute; otherwise, false. |
Example
The following example shows how to use the PersistentAliasAttribute to implement a public read-only property exposing a value of the private persistent property. The expression passed in the PersistentAliasAttribute class constructor specifies the name of the field which stores the value at runtime. The field is decorated with the PersistentAttribute whose PersistentAttribute.MapTo property holds the name of the data store column where the field’s value is stored.
using DevExpress.Xpo;
// ...
[Persistent("DefaultAddress")]
private string mDefaultAddress;
[PersistentAlias(nameof(mDefaultAddress))]
public string DefaultAddress {
get {
return mDefaultAddress;
}
}
Related GitHub Examples
The following code snippets (auto-collected from DevExpress Examples) contain references to the IsAliased property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.