Table of Contents

Struct ViewDelta

Namespace
Typhon.Engine
Assembly
Typhon.Engine.dll

A zero-allocation view into the delta state of a ViewBase (e.g. EcsView<TArchetype> or NavigationView<TSource, TTarget>).

Lifetime: This struct references the View's internal delta storage directly — no copies are made. The data is only valid until the next call to ClearDelta(). After ClearDelta(), all collections will appear empty. Do not cache this struct across refresh cycles.

Typical usage:

view.Refresh(tx);
var delta = view.GetDelta();
// Process delta.Added, delta.Removed, delta.Modified
view.ClearDelta();
// delta is now invalid — all collections report empty
public readonly struct ViewDelta
Inherited Members

Fields

Added

Entity PKs that entered the view since the last ClearDelta().

public readonly DeltaView Added

Field Value

DeltaView

Modified

Entity PKs that remained in the view but had field values change since the last ClearDelta().

public readonly DeltaView Modified

Field Value

DeltaView

Removed

Entity PKs that left the view since the last ClearDelta().

public readonly DeltaView Removed

Field Value

DeltaView

Properties

IsEmpty

true when no entities were added, removed, or modified.

public bool IsEmpty { get; }

Property Value

bool