Class LazyReferenceInstaller

Namespace: redb.Core.Utils
Assembly: redb.Core.dll

V4 (L.3, LAZY plan §3.5): after deserialization every UNLOADED reference stub in a Props graph gets the lazy loader
attached, so the first access to its Props loads exactly that object — whose own references are again stubs (the
loader passes depth 1, §4.7). The walk descends only into LOADED objects via their raw Props (never through the getter,
which would trigger loading), mirrors the shape of CacheNestedObjects, and tracks visited instances against
cycles.

Owner decision 2026-09-15 (plan docs/V4/PROPS_CACHE_PROD_AND_TAILS_PLAN.md §4.1): a data object owns no connection. A
loader bound to one scope is never installed on a stub: the stub gets the scope-free loader of that loader's database,
which loads on the scope current for the reader, else on the materializing scope (the origin) while it lives. List items
are bound the same way. A cache marks its graph shared: its stubs and items lose the origin and load on the reader's
scope only.

public static class LazyReferenceInstaller

Inheritance

Object→LazyReferenceInstaller

Methods

Install(IRedbObject?, ILazyPropsLoader?)

Attach the loader of loader's database to every unloaded reference stub under

public static void Install(IRedbObject? root, ILazyPropsLoader? loader)

InstallInto(object?, ILazyPropsLoader?)

Same walk from an arbitrary node - a Props object, a collection, a list item - for callers that hold no root.

public static void InstallInto(object? node, ILazyPropsLoader? loader)

IsLeafCollection(object)

True for a collection that can hold no reference at all - an array or a System generic

public static bool IsLeafCollection(object node)

IsWalkedProperty(PropertyInfo)

True for a property a walk of a loaded graph reads: the set the scheme and the save take - public, not an

public static bool IsWalkedProperty(PropertyInfo property)

IsWalkLeaf(object)

True for a node no reflective walk of a loaded graph may descend into: a

public static bool IsWalkLeaf(object node)

MarkShared(object?)

Marks a graph handed to a cache as shared by every scope: the objects, the stubs and the list items in it. A shared

public static void MarkShared(object? root)

MarkSharedAndCollect(object?)

The same walk as , and the loaded objects it passed are returned: one pass serves both

public static List<IRedbObject> MarkSharedAndCollect(object? root)

MarkUnloadedWherePropsAreNull(object?)

V4 (review): after deserialization, every RedbObject<T> in the graph whose Props are

public static void MarkUnloadedWherePropsAreNull(object? root)