Back to Devexpress

XPWeakReference Class

xpo-devexpress-dot-xpo-406b5dd3.md

latest2.0 KB
Original Source

XPWeakReference Class

A persistent weak reference to a persistent object.

Namespace : DevExpress.Xpo

Assembly : DevExpress.Xpo.v25.2.dll

NuGet Package : DevExpress.Xpo

Declaration

csharp
[MemberDesignTimeVisibility(false)]
[Indices("TargetType_;TargetKey_;GCRecord")]
public class XPWeakReference :
    XPCustomObject,
    IXPOServiceClass
vb
<MemberDesignTimeVisibility(False)>
<Indices("TargetType_;TargetKey_;GCRecord")>
Public Class XPWeakReference
    Inherits XPCustomObject
    Implements IXPOServiceClass

Remarks

A weak reference refers to an object but still allows it to be garbage collected.

A persistent weak reference can be used in the following instances:

  • when a persistent object needs to refer to another object whose type cannot be specified at the time the program code is written;
  • when you need to create a reference to an object but allow it to be garbage collected.

The object referenced by the XPWeakReference is specified by the XPWeakReference.Target property.

Implements

IXPObject

IXPSimpleObject

ISessionProvider

IXPModificationsStore

Inheritance

Object PersistentBase XPBaseObject XPCustomObject XPWeakReference

See Also

XPWeakReference Members

XPBaseObject

PersistentAttribute

DevExpress.Xpo Namespace