< Summary

Information
Class: GridForge.Grids.GridNavigationBodyTraceCell
Assembly: GridForge
File(s): /home/runner/work/GridForge/GridForge/src/GridForge/Grids/Support/GridNavigationBodyTraceCell.cs
Line coverage
100%
Covered lines: 6
Uncovered lines: 0
Coverable lines: 6
Total lines: 44
Line coverage: 100%
Branch coverage
N/A
Covered branches: 0
Total branches: 0
Branch coverage: N/A
Method coverage

Feature is only available for sponsors

Upgrade to PRO version

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity Line coverage
.ctor(...)100%11100%

File(s)

/home/runner/work/GridForge/GridForge/src/GridForge/Grids/Support/GridNavigationBodyTraceCell.cs

#LineLine coverage
 1//=======================================================================
 2// GridNavigationBodyTraceCell.cs
 3//=======================================================================
 4// MIT License, Copyright (c) 2024-present David Oravsky (mrdav30)
 5// See LICENSE file in the project root for full license information.
 6//=======================================================================
 7
 8using GridForge.Configuration;
 9using GridForge.Spatial;
 10
 11namespace GridForge.Grids;
 12
 13/// <summary>Identifies one topology cell and its physical generation evidence.</summary>
 14public readonly struct GridNavigationBodyTraceCell
 15{
 16    /// <summary>The exact world, grid-generation, and topology-local address.</summary>
 17    public WorldVoxelIndex Cell { get; }
 18
 19    /// <summary>The normalized grid binding key, independent of its recyclable runtime slot.</summary>
 20    public GridConfigurationKey ConfigurationKey { get; }
 21
 22    /// <summary>Whether physical storage contained this address during the trace.</summary>
 23    public bool IsPhysicallyPresent { get; }
 24
 25    /// <summary>The last committed sequence applied to the owning grid generation.</summary>
 26    public ulong GridLastChangeSequence { get; }
 27
 28    /// <summary>How this identity participates in the physical coverage proof.</summary>
 29    public GridNavigationBodyTraceCellRole Role { get; }
 30
 31    internal GridNavigationBodyTraceCell(
 32        WorldVoxelIndex cell,
 33        GridConfigurationKey configurationKey,
 34        bool isPhysicallyPresent,
 35        ulong gridLastChangeSequence,
 36        GridNavigationBodyTraceCellRole role)
 37    {
 160538        Cell = cell;
 160539        ConfigurationKey = configurationKey;
 160540        IsPhysicallyPresent = isPhysicallyPresent;
 160541        GridLastChangeSequence = gridLastChangeSequence;
 160542        Role = role;
 160543    }
 44}