xpo-devexpress-dot-xpo-dot-metadata-dot-xpmemberinfo-ddaff2f9.md
Gets the XPClassInfo of the referenced object if the member is a reference to another persistent object.
Namespace : DevExpress.Xpo.Metadata
Assembly : DevExpress.Xpo.v25.2.dll
NuGet Package : DevExpress.Xpo
public virtual XPClassInfo ReferenceType { get; }
Public Overridable ReadOnly Property ReferenceType As XPClassInfo
| Type | Description |
|---|---|
| XPClassInfo |
An XPClassInfo object which provides the metadata of the referenced object.
|
The following code snippets (auto-collected from DevExpress Examples) contain references to the ReferenceType 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.
XPO_how-to-implement-odata4-service-with-xpo-netcore/CS/ODataService/Helpers/ApiHelper.cs#L44
collection.Add(reference);
} else if(memberInfo.ReferenceType != null) {
var reference = uow.GetObjectByKey(memberInfo.ReferenceType, relatedKey);
XPO_how-to-implement-odata4-service-with-xpo/CS/ODataService/Helpers/ApiHelper.cs#L53
collection.Add(reference);
} else if(memberInfo.ReferenceType != null) {
var reference = uow.GetObjectByKey(memberInfo.ReferenceType, relatedKey);
XPO_how-to-get-a-list-of-a-persistent-objects-properties-e725/CS/Form1.cs#L115
result.Add(m.Name);
if(m.ReferenceType != null) {
string[] childProps = GetObjectProperties(m.ReferenceType, processed);
XPO_how-to-clone-a-persistent-object-e804/CS/SimpleObject/CloneHelper.cs#L52
object clonedValue = null;
if (memberInfo.ReferenceType != null) {
object value = memberInfo.GetValue(source);
xpo-json-serialization/CS/XpoSerialization/JsonConverters.cs#L26
object propertyValue = member.GetValue(theObject);
if(propertyValue != null && member.ReferenceType != null && !member.IsAggregated && !EvaluatorProperty.GetIsThisProperty(member.Name)) {
propertyValue = member.ReferenceType.KeyProperty.GetValue(propertyValue);
XPO_how-to-get-a-list-of-a-persistent-objects-properties-e725/VB/Form1.vb#L113
result.Add(m.Name)
If m.ReferenceType IsNot Nothing Then
Dim childProps As String() = GetObjectProperties(m.ReferenceType, processed)
XPO_how-to-clone-a-persistent-object-e804/VB/SimpleObject/CloneHelper.vb#L55
Dim clonedValue As Object = Nothing
If memberInfo.ReferenceType IsNot Nothing Then
Dim value As Object = memberInfo.GetValue(source)
See Also