WeakReference

This class implements a weak reference wrapper for class T.

A weak reference will not prevent the object from being collected in a garbage collection cycle. If and when the object is collected, the internal reference to object will become null.

This weak reference wrapper is thread safe.

Constructors

this
this(T object)

Create a weak reference wrapper for a given object.

Destructor

A destructor is present on this object, but not explicitly documented in the source.

Members

Functions

get
T get()

Return the referenced object held in this weak reference wrapper. If and when the object is collected, this function will return null.

opEquals
bool opEquals(Object other)
bool opEquals(const(Object) other)

Meta