Table of Contents

Namespace KeenEyes

Classes

Archetype

An archetype stores all entities that share the same set of component types. Entities are stored in fixed-size chunks for cache-friendly iteration and reduced GC pressure.

ArchetypeChunk

A fixed-size block of entity storage within an archetype. Chunks provide cache-friendly memory layout and enable pooling for reduced GC pressure.

ArchetypeManager

Manages archetype lifecycle and entity-to-archetype mappings. Handles archetype creation, entity migration, and query matching.

BuilderIgnoreAttribute

Excludes a field from the generated fluent builder method parameters. The field will use its default value.

BundleAttribute

Marks a struct as a component bundle. Source generators will produce:

  • IBundle interface implementation
  • Constructor accepting all bundle components
  • Fluent builder methods (WithBundleName)
ChunkPool

Manages pooling and reuse of archetype chunks to reduce GC pressure.

CommandBuffer

Supports all classes in the .NET class hierarchy and provides low-level services to derived classes. This is the ultimate base class of all .NET classes; it is the root of the type hierarchy.

CommandBufferPool

Provides per-system isolated command buffers for parallel system execution.

ComponentArrayPoolManager

Per-world manager for pooled component arrays. Provides pooled arrays for component storage, reducing garbage collection pressure. Uses .NET's built-in ArrayPool<T>.Shared for efficient memory reuse.

ComponentArray<T>

Typed component storage for an archetype, using pooled arrays for efficiency. Stores components contiguously in memory for cache-friendly iteration.

ComponentAttribute

Marks a struct as an ECS component. Source generators will produce:

  • Component ID and metadata
  • Fluent builder methods (WithComponentName)
  • Serialization code (if Serializable = true)
ComponentDependencies

Represents the component read/write dependencies of a system.

ComponentInfo

Runtime metadata for a registered component type within a specific World.

ComponentMeta<T>

Compile-time metadata for a component type. This is generated by the source generator and contains no instance state.

ComponentRegistry

Registry that tracks component types for a specific World. Each World has its own registry, allowing isolated ECS instances.

ComponentValidationException

Exception thrown when component validation fails during entity creation or modification.

ComponentValidationManager

Manages component validation constraints including dependencies, conflicts, and custom validators.

ConflictsWithAttribute

Specifies that a component conflicts with another component and cannot coexist on the same entity.

DefaultValueAttribute

Specifies a default value for a component field in generated builder methods.

DisplayNameAttribute

Specifies a custom display name for the field in the editor inspector.

EntityBuilder

Fluent builder for creating entities with components.

EntityCommands

Fluent builder for configuring a spawned entity in a command buffer.

EntityPool

Manages entity ID recycling with version tracking. Reduces allocations by reusing entity IDs after entities are destroyed.

EventSubscription

Represents a subscription to an event that can be unsubscribed by disposing.

FixedComponentArray<T>

Fixed-capacity component storage for use in archetype chunks. Unlike ComponentArray<T>, this array does not grow and uses a simple pre-allocated array for predictable memory layout.

FoldoutGroupAttribute

Groups fields under a foldout section in the editor inspector.

HeaderAttribute

Displays a header above the field in the editor inspector.

HideInInspectorAttribute

Hides the field from the editor inspector.

HotPathAttribute

Marks a method as a hot path that runs frequently (e.g., every frame).

MigrateFromAttribute

Marks a static method as a migration handler for upgrading component data from an older schema version.

MixinAttribute

Marks a component type to include all fields from one or more mixin types. The source generator will copy all fields from the mixin types into the component at compile-time.

OptionalAttribute

Marks a field as optional.

ParallelQueryExtensions

Provides parallel iteration extensions for query builders.

ParallelSystemBatcher

Analyzes system dependencies and groups systems into parallel execution batches.

PluginContext

Provides context for plugin installation and uninstallation operations.

PluginExtensionAttribute

Marks a class as a plugin extension that should generate a typed accessor property on World.

QueryAttribute

Marks a struct as a query definition. Source generators will produce an efficient enumerator for iterating matching archetypes.

QueryDescription

Describes which components a query includes, requires, and excludes.

QueryManager

Manages query caching and archetype matching for efficient query execution. Caches archetype matches per query descriptor and invalidates on archetype changes.

RangeAttribute

Constrains a numeric field to a range and displays it as a slider.

ReadOnlyInInspectorAttribute

Displays the field as read-only in the editor inspector.

RequiresComponentAttribute

Specifies that a component requires another component to be present on the same entity.

RunAfterAttribute

Specifies that this system must run after another system.

RunBeforeAttribute

Specifies that this system must run before another system.

SceneManager

Manages scene spawning, unloading, and entity scene membership.

SerializeEngineComponentsAttribute

Opts engine-provided components into this assembly's generated ComponentSerializer.

SpaceAttribute

Adds vertical spacing before the field in the editor inspector.

SystemAttribute

Marks a class as an ECS system for auto-discovery and registration.

SystemBase

Base class for ECS systems with common functionality.

SystemDependencyTracker

Tracks component dependencies for all registered systems.

SystemGroup

A group of systems that execute together. Useful for organizing systems by phase or feature.

TagComponentAttribute

Marks a struct as a tag component (zero-size marker). Tag components have no data and are used purely for filtering queries.

TextAreaAttribute

Indicates that a string field should be displayed as a multi-line text area.

TooltipAttribute

Provides a tooltip for the field in the editor inspector.

WithAttribute

Marks a field in a query struct as a filter requirement. The entity must have this component, but it won't be accessible in the query.

WithoutAttribute

Marks a field in a query struct as an exclusion filter. The entity must NOT have this component.

World

The world is the container for all entities and their components. Each world is completely isolated with its own component registry.

WorldBuilder

Fluent builder for configuring and creating independent World instances.

Structs

ArchetypeId

Unique identifier for an archetype based on its component type combination. Two archetypes with the same set of component types will have the same ArchetypeId.

ArchetypeStatistics

Provides statistics for a single archetype in the ECS world.

BatchAnalysis

Contains the results of batch analysis.

ChunkPoolStats

Statistics for chunk pool usage.

ComponentId

Unique identifier for a component type.

Entity

Represents an entity in the ECS world. An entity is essentially just an ID - components give it data and behavior.

MemoryStats

Provides memory usage statistics for an ECS world. Useful for monitoring, profiling, and debugging memory consumption.

QueryBuilder

Fluent builder for constructing queries.

QueryDescriptor

Immutable descriptor for a query, used as a cache key. Two queries with the same With and Without types produce the same descriptor.

QueryEnumerator

Enumerator for iterating over entities matching a query. Uses archetype-based iteration for cache-friendly performance.

SystemBatch

Represents a batch of systems that can execute in parallel.

SystemConflict

Represents a conflict between two systems.

TypeBatch

Represents a batch of system types that can execute in parallel.

WorldEntityRef

Reference to an entity in another world.

Interfaces

IBundle

Marker interface for component bundles. Bundles are compositions of multiple components commonly used together.

ICommandBuffer

Queues entity operations for deferred execution, enabling safe modification during system iteration.

IComponent

Marker interface for ECS components. Components are data containers attached to entities.

IComponentArray

Non-generic interface for component storage within an archetype. Enables heterogeneous collection of typed component arrays.

IEntityBuilder

Interface for fluent entity builders. Implemented by EntityBuilder, PrefabBuilder, etc.

IEntityBuilder<TSelf>

Strongly-typed entity builder interface for better fluent API support.

ILoopProvider

Interface for plugins that provide a main loop (window, game loop, etc.).

IPluginContext

Interface for plugin context that provides access to system registration and extension APIs.

IQueryBuilder

Interface for fluent query building.

ISystem

Interface for ECS systems that process entities.

ISystemDependencyBuilder

Fluent builder for declaring system component dependencies.

ISystemDependencyProvider

Interface for systems that explicitly declare their component dependencies.

ISystemLifecycle

Optional interface for systems that need before/after update lifecycle hooks.

ITagComponent

Marker interface for tag components (zero-size markers). Tag components have no data and are used purely for filtering queries.

IWorld

Interface for ECS world operations used by systems and plugins.

IWorldPlugin

Interface for world plugins that provide modular functionality to an ECS world.

Enums

SystemPhase

Defines when a system executes in the game loop.

ValidationMode

Specifies the validation mode for component constraints in a World.

Delegates

ComponentValidationManager.TryGetConstraintsDelegate

Delegate type for the generated TryGetConstraints method.

ComponentValidator<T>

Delegate for custom component validation.

EntityActionReadOnly<T1>

Delegate for processing an entity with one readonly component.

EntityActionReadOnly<T1, T2>

Delegate for processing an entity with two readonly components.

EntityActionReadOnly<T1, T2, T3>

Delegate for processing an entity with three readonly components.

EntityActionReadOnly<T1, T2, T3, T4>

Delegate for processing an entity with four readonly components.

EntityAction<T1>

Delegate for processing an entity with one component.

EntityAction<T1, T2>

Delegate for processing an entity with two components.

EntityAction<T1, T2, T3>

Delegate for processing an entity with three components.

EntityAction<T1, T2, T3, T4>

Delegate for processing an entity with four components.

SystemHook

Represents a callback that is invoked before or after a system executes.