SPECIALIZED COLLECTIONS FOR .NET HOT PATHS
Put your data where the work is.
SwiftCollections gives simulations, games, spatial systems, and allocation-sensitive tools tighter control over storage, dense iteration, handles, pooling, and broad-phase queries.
Start with the workload
Compact integer IDs
Use sparse sets and maps for constant-time lookup plus dense iteration when your system already owns small non-negative IDs.
Stable handles
Use slot maps for reusable slots, or ticket maps when stale references must stop resolving after a slot is reused.
Spatial queries
Choose BVH, spatial hash, or octree structures for broad-phase searches over floating-point or FixedMathSharp-backed bounds.
Pick a package family
Standard
SwiftCollections includes the core collections and
MemoryPack support.
Lean
SwiftCollections.Lean keeps the collection APIs without the
MemoryPack runtime dependency.
FixedMathSharp
Add the matching SwiftCollections.FixedMathSharp companion
for deterministic fixed-point query volumes.
Unity packages
Use the maintained Unity host for serializable authoring adapters,
Bounds conversion, GameObject pooling, and samples.
Guides
- Get started with packages and a first container.
- Choose collections and clearing policies for the ownership model.
- Query spatial bounds, including fixed-point volumes.
- Manage rentals and notifications at host boundaries.
- Serialize state and configure diagnostics.
Part of the LSF ecosystem
SwiftCollections provides specialized collections and spatial indexes for libraries, games, simulations, and tools throughout the Lockstep Simulation Framework ecosystem:
Resources
The API reference is generated from the source XML documentation. The overview explains tradeoffs, ID density constraints, serialization state, spatial query semantics, and the development workflow.