This is the full API documentation of DefaultEcs.
The DefaultEcs namespace contains types to put in place the Entity Component System pattern.
- AoTHelper
ClassProvides a set of methods to help the generation of generic code for AoT compilation.- RegisterComponent<T>()
MethodRegisters the type T so it can freely be used in ComponentAttribute. - RegisterMessage<T>()
MethodRegisters the type T so SubscribeAttribute can freely be used on method like the delegate MessageHandler<T>(T) to automatically subscribe when using IPublisherExtension on a World instance. - RegisterUnmanagedComponent<T>()
MethodRegisters the unmanaged type T so it can freely be used in ComponentAttribute and by Set<T>(T).
- RegisterComponent<T>()
- ComponentCloner
ClassExposes a way to clone one Entity components to an other.- ComponentCloner()
ConstructorInitialize a new instance of the ComponentCloner type. - Clone(Entity, Entity)
MethodClones one Entity components to an other. - OnComponent<T>(T, bool)
MethodHandles the component of type T from the source Entity. - Set<T>(T, bool)
MethodSets the given component on the copied entity.
- ComponentCloner()
- EntityMap<TKey>
ClassRepresents a collection of Entity mapped to a TKey component. Only one Entity can be associated with a given TKey.- Keys
PropertyGets the keys contained in the EntityMap<TKey>. - this[TKey]
PropertyGets the Entity associated with the specified key. - World
PropertyGets the World instance from which current DefaultEcs.IEntityContainer originate. - Complete()
MethodClears current instance of its entities if it was created with some reactive filter (WhenAdded<T>(), WhenChanged<T>() or WhenRemoved<T>()).
Does nothing if it was created from a static filter.
This method need to be called after current instance content has been processed in a update cycle. - Contains(Entity)
MethodDetermines whether the DefaultEcs.IEntityContainer contains a specific Entity. - ContainsKey(TKey)
MethodDetermines whether the EntityMap<TKey> contains the specified key. - Dispose()
MethodReleases current EntityMap<TKey> of its subscriptions, stopping it to get modifications on the World's Entity. - TrimExcess()
MethodResizes inner storage to exactly the number of Entity this DefaultEcs.IEntityContainer contains. - TryGetEntity(TKey, Entity)
MethodGets the Entity associated with the specified key. - EntityAdded
EventOccurs when an Entity is added in the current DefaultEcs.IEntityContainer. - EntityRemoved
EventOccurs when an Entity is removed from the current DefaultEcs.IEntityContainer.
- Keys
- EntityMultiMap<TKey>
ClassRepresents a collection of Entity mapped to a TKey component. Multiple Entity can be associated with a given TKey.- Keys
PropertyGets the keys contained in the EntityMultiMap<TKey>. - this[TKey]
PropertyGets the Entity instances associated with the specified key. - World
PropertyGets the World instance from which current DefaultEcs.IEntityContainer originate. - Complete()
MethodClears current instance of its entities if it was created with some reactive filter (WhenAdded<T>(), WhenChanged<T>() or WhenRemoved<T>()).
Does nothing if it was created from a static filter.
This method need to be called after current instance content has been processed in a update cycle. - Contains(Entity)
MethodDetermines whether the DefaultEcs.IEntityContainer contains a specific Entity. - ContainsKey(TKey)
MethodDetermines whether the EntityMultiMap<TKey> contains the specified key. - Count(TKey)
MethodGets the number of Entity in the current EntityMultiMap<TKey> for the given TKey. - Dispose()
MethodReleases current EntitySet of its subscriptions, stopping it to get modifications on the World's Entity. - TrimExcess()
MethodResizes inner storage to exactly the number of Entity this DefaultEcs.IEntityContainer contains. - TryGetEntities(TKey, ReadOnlySpan<Entity>)
MethodGets the Entity instances associated with the specified key. - EntityAdded
EventOccurs when an Entity is added in the current DefaultEcs.IEntityContainer. - EntityRemoved
EventOccurs when an Entity is removed from the current DefaultEcs.IEntityContainer.
- Keys
- EntityQueryBuilder
ClassRepresent an helper object to create rules to retrieve a specific subset of Entity.- AsEnumerable()
MethodReturns an System.Collections.Generic.IEnumerable<> of Entity with the specified rules. - AsMap<TKey>()
MethodReturns an EntityMap<TKey> with the specified rules. - AsMap<TKey>(int)
MethodReturns an EntityMap<TKey> with the specified rules. - AsMap<TKey>(int, IEqualityComparer<TKey>)
MethodReturns an EntityMap<TKey> with the specified rules. - AsMap<TKey>(IEqualityComparer<TKey>)
MethodReturns an EntityMap<TKey> with the specified rules. - AsMultiMap<TKey>()
MethodReturns an EntityMultiMap<TKey> with the specified rules. - AsMultiMap<TKey>(int)
MethodReturns an EntityMultiMap<TKey> with the specified rules. - AsMultiMap<TKey>(int, IEqualityComparer<TKey>)
MethodReturns an EntityMultiMap<TKey> with the specified rules. - AsMultiMap<TKey>(IEqualityComparer<TKey>)
MethodReturns an EntityMultiMap<TKey> with the specified rules. - AsPredicate()
MethodReturns a System.Predicate<> representing the specified rules. - AsSet()
MethodReturns an EntitySet with the specified rules. - AsSortedSet<TComponent>()
MethodReturns an EntitySortedSet<TComponent> with the specified rules. - AsSortedSet<TComponent>(IComparer<TComponent>)
MethodReturns an EntitySortedSet<TComponent> with the specified rules. - Copy()
MethodCopies all the rules of the current EntityQueryBuilder to a new instance. - WhenAdded<T>()
MethodMakes a rule to observe Entity when a component of type T is added. - WhenAddedEither<T>()
MethodMakes a rule to observe Entity when one component of the either group is added. - WhenChanged<T>()
MethodMakes a rule to observe Entity when a component of type T is changed. - WhenChangedEither<T>()
MethodMakes a rule to observe Entity when one component of the either group is changed. - WhenRemoved<T>()
MethodMakes a rule to observe Entity when a component of type T is removed. - WhenRemovedEither<T>()
MethodMakes a rule to observe Entity when one component of the either group is removed. - With<T>()
MethodMakes a rule to observe Entity with a component of type T. - With<T>(ComponentPredicate<T>)
MethodMakes a rule to observe Entity with a component of type T validating the given ComponentPredicate<T>(T). - WithEither<T>()
MethodMakes a rule to obsverve Entity with at least one component of the either group. - Without<T>()
MethodMakes a rule to ignore Entity with a component of type T. - WithoutEither<T>()
MethodMakes a rule to obsverve Entity without at least one component of the either group.
- AsEnumerable()
- EntityQueryBuilder.EitherBuilder
ClassRepresents an helper object to create an either group rule to retrieve a specific subset of Entity.- AsEnumerable()
MethodReturns an System.Collections.Generic.IEnumerable<> of Entity with the specified rules. - AsMap<TKey>()
MethodReturns an EntityMap<TKey> with the specified rules. - AsMap<TKey>(int)
MethodReturns an EntityMap<TKey> with the specified rules. - AsMap<TKey>(int, IEqualityComparer<TKey>)
MethodReturns an EntityMap<TKey> with the specified rules. - AsMap<TKey>(IEqualityComparer<TKey>)
MethodReturns an EntityMap<TKey> with the specified rules. - AsMultiMap<TKey>()
MethodReturns an EntityMultiMap<TKey> with the specified rules. - AsMultiMap<TKey>(int)
MethodReturns an EntityMultiMap<TKey> with the specified rules. - AsMultiMap<TKey>(int, IEqualityComparer<TKey>)
MethodReturns an EntityMultiMap<TKey> with the specified rules. - AsMultiMap<TKey>(IEqualityComparer<TKey>)
MethodReturns an EntityMultiMap<TKey> with the specified rules. - AsPredicate()
MethodReturns a System.Predicate<> representing the specified rules. - AsSet()
MethodReturns an EntitySet with the specified rules. - AsSortedSet<TComponent>()
MethodReturns an EntitySortedSet<TComponent> with the specified rules. - AsSortedSet<TComponent>(IComparer<TComponent>)
MethodReturns an EntitySortedSet<TComponent> with the specified rules. - Copy()
MethodCopies all the rules of the current EntityQueryBuilder to a new instance. - Or<T>()
MethodAdd the type T to current either group. - WhenAdded<T>()
MethodMakes a rule to observe Entity when a component of type T is added. - WhenAddedEither<T>()
MethodMakes a rule to observe Entity when one component of the either group is added. - WhenChanged<T>()
MethodMakes a rule to observe Entity when a component of type T is changed. - WhenChangedEither<T>()
MethodMakes a rule to observe Entity when one component of the either group is changed. - WhenRemoved<T>()
MethodMakes a rule to observe Entity when a component of type T is removed. - WhenRemovedEither<T>()
MethodMakes a rule to observe Entity when one component of the either group is removed. - With<T>()
MethodMakes a rule to observe Entity with a component of type T. - With<T>(ComponentPredicate<T>)
MethodMakes a rule to observe Entity with a component of type T validating the given ComponentPredicate<T>(T). - WithEither<T>()
MethodMakes a rule to obsverve Entity with at least one component of the either group. - Without<T>()
MethodMakes a rule to ignore Entity with a component of type T. - WithoutEither<T>()
MethodMakes a rule to obsverve Entity without at least one component of the either group.
- AsEnumerable()
- EntityQueryBuilderExtension
ClassProvides set of static methods to create more easily rules on a EntityQueryBuilder instance.- WhenAdded(this EntityQueryBuilder, Type[])
MethodMakes a rule to obsverve Entity when all component of the given types are added. - WhenAddedEither(this EntityQueryBuilder, Type[])
MethodMakes a rule to observe Entity when one component of the given types is added. - WhenChanged(this EntityQueryBuilder, Type[])
MethodMakes a rule to obsverve Entity when all component of the given types are changed. - WhenChangedEither(this EntityQueryBuilder, Type[])
MethodMakes a rule to observe Entity when one component of the given types is changed. - WhenRemoved(this EntityQueryBuilder, Type[])
MethodMakes a rule to obsverve Entity when all component of the given types are removed. - WhenRemovedEither(this EntityQueryBuilder, Type[])
MethodMakes a rule to observe Entity when one component of the given types is removed. - With(this EntityQueryBuilder, Type[])
MethodMakes a rule to obsverve Entity with all component of the given types. - WithEither(this EntityQueryBuilder, Type[])
MethodMakes a rule to obsverve Entity with at least one component of the given types. - Without(this EntityQueryBuilder, Type[])
MethodMakes a rule to ignore Entity with at least one component of the given types. - WithoutEither(this EntityQueryBuilder, Type[])
MethodMakes a rule to obsverve Entity without at least one component of the given types.
- WhenAdded(this EntityQueryBuilder, Type[])
- EntitySet
ClassRepresents a sub-selection of Entity instances from a World.- Count
PropertyGets the number of Entity in the current EntitySet. - World
PropertyGets the World instance from which current DefaultEcs.IEntityContainer originate. - Complete()
MethodClears current instance of its entities if it was created with some reactive filter (WhenAdded<T>(), WhenChanged<T>() or WhenRemoved<T>()).
Does nothing if it was created from a static filter.
This method need to be called after current instance content has been processed in a update cycle. - Contains(Entity)
MethodDetermines whether the DefaultEcs.IEntityContainer contains a specific Entity. - Dispose()
MethodReleases current EntitySet of its subscriptions, stopping it to get modifications on the World's Entity. - GetEntities()
MethodGets the Entity contained in the current EntitySet. - TrimExcess()
MethodResizes inner storage to exactly the number of Entity this DefaultEcs.IEntityContainer contains. - EntityAdded
EventOccurs when an Entity is added in the current DefaultEcs.IEntityContainer. - EntityRemoved
EventOccurs when an Entity is removed from the current DefaultEcs.IEntityContainer.
- Count
- EntitySortedSet<TComponent>
ClassRepresents a sub-selection of Entity instances from a World sorted by a specific component.- Count
PropertyGets the number of Entity in the current EntitySortedSet<TComponent>. - World
PropertyGets the World instance from which current DefaultEcs.IEntityContainer originate. - Complete()
MethodClears current instance of its entities if it was created with some reactive filter (WhenAdded<T>(), WhenChanged<T>() or WhenRemoved<T>()).
Does nothing if it was created from a static filter.
This method need to be called after current instance content has been processed in a update cycle. - Contains(Entity)
MethodDetermines whether the DefaultEcs.IEntityContainer contains a specific Entity. - Dispose()
MethodReleases current EntitySortedSet<TComponent> of its subscriptions, stopping it to get modifications on the World's Entity. - GetEntities()
MethodGets the Entity contained in the current EntitySortedSet<TComponent>. - TrimExcess()
MethodResizes inner storage to exactly the number of Entity this DefaultEcs.IEntityContainer contains. - EntityAdded
EventOccurs when an Entity is added in the current DefaultEcs.IEntityContainer. - EntityRemoved
EventOccurs when an Entity is removed from the current DefaultEcs.IEntityContainer.
- Count
- IPublisherExtension
ClassProvides set of static methods to automatically subscribe MessageHandler<T>(T) methods marked with the SubscribeAttribute on a IPublisher instance.- Subscribe(this IPublisher, Type)
MethodSubscribes automatically methods of a Type marked with the SubscribeAttribute on an IPublisher instance. - Subscribe<T>(this IPublisher)
MethodSubscribes automatically methods of a Type marked with the SubscribeAttribute on an IPublisher instance. - Subscribe<T>(this IPublisher, T)
MethodSubscribes automatically methods of an instance and its Type marked with the SubscribeAttribute on an IPublisher instance.
- Subscribe(this IPublisher, Type)
- SubscribeAttribute
ClassSpecifies that the method should be automatically subscribed when its parent type or instance is called with IPublisherExtension.
The decorated method should be of the type MessageHandler<T>(T). - World
ClassRepresents a item used to create and manage Entity objects.- World()
ConstructorInitializes a new instance of the World class. - World(int)
ConstructorInitializes a new instance of the World class. - MaxCapacity
PropertyGets the maximum number of Entity this World can handle. - CreateEntity()
MethodCreates a new instance of the Entity struct.
This method is not thread safe. - Dispose()
MethodCleans up all the components of existing Entity.
The current World, all Entity and EntitySet created from this instance, should not be used again after calling this method. - Get<T>()
MethodGets the component of type T on the current World. - GetAll<T>()
MethodGets all the component of a given type T. - GetComponents<T>()
MethodGets an Components<T> to get a fast access to the component of type T of this World instance Entity. - GetDisabledEntities()
MethodGets an EntityQueryBuilder to create a subset of disabled Entity of the current World. - GetEntities()
MethodGets an EntityQueryBuilder to create a subset of Entity of the current World. - GetEnumerator()
MethodReturns an enumerator that iterates through the Entity of the current World instance. - GetMaxCapacity<T>()
MethodGets the maximum number of T components this World can create. - Has<T>()
MethodReturns whether the current World has a component of type T.
It has nothing to do whether or not the current World instance has an Entity with a component of type T. - Optimize()
MethodSorts current instance inner storage so accessing Entity and their components from EntitySet and EntityMultiMap<TKey> always move forward in memory.
This method is not thread safe. - Optimize(IParallelRunner)
MethodSorts current instance inner storage so accessing Entity and their components from EntitySet and EntityMultiMap<TKey> always move forward in memory.
This method is not thread safe. - Optimize(IParallelRunner, Action)
MethodSorts current instance inner storage so accessing Entity and their components from EntitySet and EntityMultiMap<TKey> always move forward in memory.
This method will return once mainAction is executed even if the optimization process has not finished.
This method is not thread safe. - Publish<T>(T)
MethodPublishes a T object. - ReadAllComponentTypes(IComponentTypeReader)
MethodCalls on reader with all the maximum number of component of the current World.
This method is primiraly used for serialization purpose and should not be called in game logic. - Remove<T>()
MethodRemoves the component of type T on the current World.
This method is not thread safe. - Set<T>()
MethodSets the value of the component of type T to its default value on the current World.
This method is not thread safe. - Set<T>(T)
MethodSets the value of the component of type T on the current World.
This method is not thread safe. - SetMaxCapacity<T>(int)
MethodSets up the current World to handle component of type T with a different maximum count than MaxCapacity.
If the type of component is already handled by the current World, does nothing.
This method is not thread safe. - Subscribe<T>(MessageHandler<T>)
MethodSubscribes an MessageHandler<T>(T) to be called back when a T object is published. - SubscribeComponentAdded<T>(ComponentAddedHandler<T>)
MethodSubscribes a ComponentAddedHandler<T>(Entity, T) on the current World to be called when a component of type T is added. - SubscribeComponentChanged<T>(ComponentChangedHandler<T>)
MethodSubscribes a ComponentChangedHandler<T>(Entity, T, T) on the current World to be called when a component of type T is changed. - SubscribeComponentDisabled<T>(ComponentDisabledHandler<T>)
MethodSubscribes a ComponentDisabledHandler<T>(Entity, T) on the current World to be called when a component of type T is disabled. - SubscribeComponentEnabled<T>(ComponentEnabledHandler<T>)
MethodSubscribes a ComponentEnabledHandler<T>(Entity, T) on the current World to be called when a component of type T is enabled. - SubscribeComponentRemoved<T>(ComponentRemovedHandler<T>)
MethodSubscribes an ComponentRemovedHandler<T>(Entity, T) on the current World to be called when a component of type T is removed. - SubscribeEntityCreated(EntityCreatedHandler)
MethodSubscribes an EntityCreatedHandler(Entity) on the current World to be called when an Entity is created. - SubscribeEntityDisabled(EntityDisabledHandler)
MethodSubscribes an EntityDisabledHandler(Entity) on the current World to be called when an Entity is disabled. - SubscribeEntityDisposed(EntityDisposedHandler)
MethodSubscribes an EntityDisposedHandler(Entity) on the current World to be called when an Entity is disposed. - SubscribeEntityEnabled(EntityEnabledHandler)
MethodSubscribes an EntityEnabledHandler(Entity) on the current World to be called when an Entity is enabled. - SubscribeWorldDisposed(WorldDisposedHandler)
MethodSubscribes an WorldDisposedHandler(World) on the current World to be called when current instance is disposed. - ToString()
MethodReturns a string representation of this instance. - TrimExcess()
MethodResizes all inner storage to exactly the number of Entity and components this World contains.
This method is not thread safe. - TrimExcess<T>()
MethodResizes inner storage to exactly the number of T components this World contains.
This method is not thread safe. - System.Collections.Generic.IEnumerable<DefaultEcs.Entity>.GetEnumerator()
Explicit Interface ImplementationReturns an enumerator that iterates through the Entity of the current World instance. - System.Collections.IEnumerable.GetEnumerator()
Explicit Interface ImplementationReturns an enumerator that iterates through the Entity of the current World instance.
- World()
- Components<T>
StructProvides a fast access to the components of type T.
Note that all entity modification operations are not safe (anything different than a simple Get<T>()) and may invalidate the Components<T>.- this[Entity]
PropertyGets the component of type T on the provided Entity.
- this[Entity]
- Entity
StructRepresents an item in the World.
Only use Entity generated from the CreateEntity() method.- IsAlive
PropertyGets whether the current Entity is alive or not. - World
PropertyGets the World instance from which current Entity originate. - CopyTo(World)
MethodCreates a copy of current Entity with all of its components in the given World.
This method is not thread safe. - CopyTo(World, ComponentCloner)
MethodCreates a copy of current Entity with all of its components in the given World using the given ComponentCloner.
This method is not thread safe. - Disable()
MethodDisables the current Entity so it does not appear in EntitySet.
This method is not thread safe. - Disable<T>()
MethodDisables the current Entity component of type T so it does not appear in EntitySet.
Does nothing if current Entity does not have a component of type T.
This method is not thread safe. - Dispose()
MethodClean the current Entity of all its components.
The current Entity should not be used again after calling this method and IsAlive will return false. - Enable()
MethodEnables the current Entity so it can appear in EntitySet.
This method is not thread safe. - Enable<T>()
MethodEnables the current Entity component of type T so it can appear in EntitySet.
Does nothing if current Entity does not have a component of type T.
This method is not thread safe. - Equals(Entity)
MethodIndicates whether the current object is equal to another object of the same type. - Equals(object)
MethodIndicates whether this instance and a specified object are equal. - Get<T>()
MethodGets the component of type T on the current Entity. - GetHashCode()
MethodReturns the hash code for this instance. - Has<T>()
MethodReturns whether the current Entity has a component of type T. - IsEnabled()
MethodGets whether the current Entity is enabled or not. - IsEnabled<T>()
MethodGets whether the current Entity component of type T is enabled or not. - NotifyChanged<T>()
MethodNotifies the value of the component of type T has changed.
This method is not thread safe. - ReadAllComponents(IComponentReader)
MethodCalls on reader with all the component of the current Entity.
This method is primiraly used for serialization purpose and should not be called in game logic. - Remove<T>()
MethodRemoves the component of type T on the current Entity.
This method is not thread safe. - Set<T>()
MethodSets the value of the component of type T to its default value on the current Entity.
This method is not thread safe. - Set<T>(T)
MethodSets the value of the component of type T on the current Entity.
This method is not thread safe. - SetSameAs<T>(Entity)
MethodSets the value of the component of type T on the current Entity to the same instance of an other Entity.
This method is not thread safe. - SetSameAsWorld<T>()
MethodSets the value of the component of type T on the current Entity to the same instance of an other Entity.
This method is not thread safe. - ToString()
MethodReturns a string representation of this instance. - operator ==(Entity, Entity)
OperatorDetermines whether two specified entities are the same. - operator !=(Entity, Entity)
OperatorDetermines whether two specified entities are not the same.
- IsAlive
- EntityMap<TKey>.KeyEnumerable
StructAllows to enumerate the TKey of a EntityMap<TKey>.- GetEnumerator()
MethodReturns an enumerator that iterates through the collection. - System.Collections.Generic.IEnumerable<TKey>.GetEnumerator()
Explicit Interface ImplementationReturns an enumerator that iterates through the collection. - System.Collections.IEnumerable.GetEnumerator()
Explicit Interface ImplementationReturns an enumerator that iterates through the collection.
- GetEnumerator()
- EntityMap<TKey>.KeyEnumerator
StructEnumerates the TKey of a EntityMap<TKey>.- Current
PropertyGets the TKey at the current position of the enumerator. - Dispose()
MethodReleases all resources used by the KeyEnumerator. - MoveNext()
MethodAdvances the enumerator to the next TKey of the EntityMap<TKey>. - System.Collections.IEnumerator.Current
Explicit Interface ImplementationGets the TKey at the current position of the enumerator. - System.Collections.IEnumerator.Reset()
Explicit Interface ImplementationSets the enumerator to its initial position, which is before the first element in the collection.
- Current
- EntityMultiMap<TKey>.KeyEnumerable
StructAllows to enumerate the TKey of a EntityMultiMap<TKey>.- GetEnumerator()
MethodReturns an enumerator that iterates through the collection. - System.Collections.Generic.IEnumerable<TKey>.GetEnumerator()
Explicit Interface ImplementationReturns an enumerator that iterates through the collection. - System.Collections.IEnumerable.GetEnumerator()
Explicit Interface ImplementationReturns an enumerator that iterates through the collection.
- GetEnumerator()
- EntityMultiMap<TKey>.KeyEnumerator
StructEnumerates the TKey of a EntityMultiMap<TKey>.- Current
PropertyGets the TKey at the current position of the enumerator. - Dispose()
MethodReleases all resources used by the KeyEnumerator. - MoveNext()
MethodAdvances the enumerator to the next TKey of the EntityMultiMap<TKey>. - System.Collections.IEnumerator.Current
Explicit Interface ImplementationGets the TKey at the current position of the enumerator. - System.Collections.IEnumerator.Reset()
Explicit Interface ImplementationSets the enumerator to its initial position, which is before the first element in the collection.
- Current
- World.Enumerator
StructEnumerates the Entity of a World.- Current
PropertyGets the Entity at the current position of the enumerator. - Dispose()
MethodReleases all resources used by the Enumerator. - MoveNext()
MethodAdvances the enumerator to the next Entity of the World. - Reset()
MethodSets the enumerator to its initial position, which is before the first Entity in the collection. - System.Collections.IEnumerator.Current
Explicit Interface ImplementationGets the Entity at the current position of the enumerator.
- Current
- IPublisher
InterfaceExposes methods to subscribe to MessageHandler<T>(T) and publish message to callback those subscriptions.- Publish<T>(T)
MethodPublishes a T object. - Subscribe<T>(MessageHandler<T>)
MethodSubscribes an MessageHandler<T>(T) to be called back when a T object is published.
- Publish<T>(T)
- ComponentAddedHandler<T>(Entity, T)
DelegateRepresents the method that will called when a component of type T is added on an Entity. - ComponentChangedHandler<T>(Entity, T, T)
DelegateRepresents the method that will called when a component of type T is removed from an Entity. - ComponentDisabledHandler<T>(Entity, T)
DelegateRepresents the method that will called when a component of type T is disabled on an Entity. - ComponentEnabledHandler<T>(Entity, T)
DelegateRepresents the method that will called when a component of type T is enabled on an Entity. - ComponentPredicate<T>(T)
DelegateRepresents the method that defines a set of criteria and determines whether the specified component meets those criteria. - ComponentRemovedHandler<T>(Entity, T)
DelegateRepresents the method that will called when a component of type T is removed from an Entity. - EntityAddedHandler(Entity)
DelegateRepresents the method that will called when an Entity is added to a container. - EntityCreatedHandler(Entity)
DelegateRepresents the method that will called when an Entity is created. - EntityDisabledHandler(Entity)
DelegateRepresents the method that will called when an Entity is disabled. - EntityDisposedHandler(Entity)
DelegateRepresents the method that will called when an Entity is disposed. - EntityEnabledHandler(Entity)
DelegateRepresents the method that will called when an Entity is enabled. - EntityRemovedHandler(Entity)
DelegateRepresents the method that will called when an Entity is removed from a container. - MessageHandler<T>(T)
DelegateEncapsulates a method that has a single in parameter and does not return a value used for Subscribe<T>(MessageHandler<T>) method. - WorldDisposedHandler(World)
DelegateRepresents the method that will called when a World is created.
The DefaultEcs.Command namespace contains types used in the recording and deferred execution of modifications on entities.
- EntityCommandRecorder
ClassRepresents a buffer of structural modifications to apply on Entity to record as postoned commands.- EntityCommandRecorder()
ConstructorCreates a default sized EntityCommandRecorder of 1ko which can grow as needed. - EntityCommandRecorder(int)
ConstructorCreates a fixed sized EntityCommandRecorder. - EntityCommandRecorder(int, int)
ConstructorCreates an EntityCommandRecorder with a custom default size which can grow to a maximum capacity. - Capacity
PropertyGets current capacity of the current instance. - MaxCapacity
PropertyGets the maximum capacity the current instance can grow to. - Size
PropertyGets the size taken by recorded commands in current instance. - Clear()
MethodClears all recorded commands. - Dispose()
MethodReleases inner unmanaged resources. - Execute()
MethodExecutes all recorded commands and clears those commands. - Record(Entity)
MethodGives an EntityRecord to record action on the given Entity.
This command takes 9 bytes. - Record(World)
MethodGives an WorldRecord to record action on the given World.
- EntityCommandRecorder()
- EntityRecord
StructRepresents an Entity on which to create commands to record in a EntityCommandRecorder.- CopyTo(World)
MethodCreates a copy of current EntityRecord with all of its components in the given World. - CopyTo(World, ComponentCloner)
MethodCreates a copy of current EntityRecord with all of its components in the given World using the given ComponentCloner. - Disable()
MethodDisables the corresponding Entity so it does not appear in EntitySet.
This command takes 5 bytes. - Disable<T>()
MethodDisables the corresponding Entity component of type T so it does not appear in EntitySet.
This command takes 9 bytes. - Dispose()
MethodClean the corresponding Entity of all its components.
The current EntityRecord should not be used again after calling this method.
This command takes 5 bytes. - Enable()
MethodEnables the corresponding Entity so it can appear in EntitySet.
This command takes 5 bytes. - Enable<T>()
MethodEnables the corresponding Entity component of type T so it can appear in EntitySet.
Does nothing if corresponding Entity does not have a component of type T.
This command takes 9 bytes. - NotifyChanged<T>()
MethodNotifies the value of the component of type T has changed on the corresponding Entity.
This command takes 9 bytes. - Remove<T>()
MethodRemoves the component of type T on the corresponding Entity.
This command takes 9 bytes. - Set<T>()
MethodSets the value of the component of type T to its default value on the corresponding Entity.
For a blittable component, this command takes 9 bytes + the size of the component.
For non blittable component, this command takes 13 bytes and may cause some allocation because of boxing on struct component type. - Set<T>(T)
MethodSets the value of the component of type T on the corresponding Entity.
For a blittable component, this command takes 9 bytes + the size of the component.
For non blittable component, this command takes 13 bytes and may cause some allocation because of boxing on struct component type. - SetSameAs<T>(EntityRecord)
MethodSets the value of the component of type T on the corresponding Entity to the same instance of an other EntityRecord.
This command takes 13 bytes. - SetSameAsWorld<T>()
MethodSets the value of the component of type T on the corresponding Entity to the same instance of its World.
This command takes 9 bytes.
- CopyTo(World)
- WorldRecord
StructRepresents a World on which to create commands to record in a EntityCommandRecorder.- CreateEntity()
MethodRecords the creation of an Entity on a World and returns an EntityRecord to record action on it.
This command takes 9 bytes. - Remove<T>()
MethodRemoves the component of type T on the corresponding World.
This command takes 7 bytes. - Set<T>()
MethodSets the value of the component of type T to its default value on the corresponding World.
For a blittable component, this command takes 7 bytes + the size of the component.
For non blittable component, this command takes 11 bytes and may cause some allocation because of boxing on struct component type. - Set<T>(T)
MethodSets the value of the component of type T on the corresponding World.
For a blittable component, this command takes 7 bytes + the size of the component.
For non blittable component, this command takes 11 bytes and may cause some allocation because of boxing on struct component type.
- CreateEntity()
The DefaultEcs.Resource namespace contains types used in the loading of unmanaged resources needed as components.
- AResourceManager<TInfo,TResource>
ClassBase type used to load resources of type TResource using info of type TInfo.
TInfo is used as key if the same resource is requested on multiple Entity to only load the TResource resource once.
If no Entity contains the ManagedResource<TInfo,TResource> component identifying the resource anymore, the TResource instance is then unloaded automatically.
By default, if TResource is System.IDisposable, Unload(TInfo, TResource) will call the System.IDisposable.Dispose method of the resource.- AResourceManager()
ConstructorCreates an instance of type AResourceManager<TInfo,TResource>. - Resources
PropertyGets all the TResource loaded by the current instance and their corresponding TInfo. - Dispose()
MethodUnloads all loaded resources. - Load(TInfo)
MethodLoads a resource of type TResource using the provided TInfo parameter. - Manage(World)
MethodSets up current AResourceManager<TInfo,TResource> instance to react to ManagedResource<TInfo,TResource> components on Entity instances of the provided World.
Once no Entity contains a ManagedResource<TInfo,TResource> component anymore, the shared TResource resource is disposed automatically. - OnResourceLoaded(Entity, TInfo, TResource)
MethodCalled when a resource is loaded from a ManagedResource<TInfo,TResource> component of an Entity. - Unload(TInfo, TResource)
MethodUnloads a resource once it is no longer referenced by a ManagedResource<TInfo,TResource>.
By default if TResource is System.IDisposable, calls the System.IDisposable.Dispose method.
- AResourceManager()
- ManagedResource<TResource>
ClassProvides static methods for creating ManagedResource<TInfo,TResource> object.- Create<TInfo>(TInfo)
MethodCreate a ManagedResource<TInfo,TResource> object - Create<TInfo>(TInfo[])
MethodCreate a ManagedResource<TInfo,TResource> object with multiple infos.
- Create<TInfo>(TInfo)
- AResourceManager<TInfo,TResource>.ResourceEnumerable
StructAllows to enumerate the resources of a AResourceManager<TInfo,TResource>.- GetEnumerator()
MethodReturns an enumerator that iterates through the collection. - System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<TInfo,TResource>>.GetEnumerator()
Explicit Interface ImplementationReturns an enumerator that iterates through the collection. - System.Collections.IEnumerable.GetEnumerator()
Explicit Interface ImplementationReturns an enumerator that iterates through the collection.
- GetEnumerator()
- AResourceManager<TInfo,TResource>.ResourceEnumerator
StructEnumerates the resources of a AResourceManager<TInfo,TResource>.- Current
PropertyGets the resource at the current position of the enumerator. - Dispose()
MethodReleases all resources used by the ResourceEnumerator. - MoveNext()
MethodAdvances the enumerator to the next resource of the AResourceManager<TInfo,TResource>. - System.Collections.IEnumerator.Current
Explicit Interface ImplementationGets the resource at the current position of the enumerator. - System.Collections.IEnumerator.Reset()
Explicit Interface ImplementationSets the enumerator to its initial position, which is before the first element in the collection.
- Current
- ManagedResource<TInfo,TResource>
StructComponent type used to load managed resource with a AResourceManager<TInfo,TResource>.- ManagedResource(TInfo)
ConstructorCreates a component of type ManagedResource<TInfo,TResource> used to load a resource of type TResource. - Info
FieldGets the info about the resource to load.
- ManagedResource(TInfo)
The DefaultEcs.Serialization namespace contains types used to save and load DefaultEcs objects.
- BinarySerializationContext
ClassRepresents a context used by the BinarySerializer to convert types during serialization and deserialization operations.
The context marshalling will not be applied on members of unmanaged type as BinarySerializer just past their memory location with no transformation.- BinarySerializationContext()
ConstructorInitializes a new instance of the BinarySerializationContext class. - Dispose()
MethodReleases inner resources. - Marshal<TIn,TOut>(Func<TIn,TOut>)
MethodAdds a convertion between the type TIn and the type TOut during a serialization operation. - Unmarshal<TIn,TOut>(Func<TIn,TOut>)
MethodAdds a convertion between the type TIn and the type TOut during a deserialization operation.
- BinarySerializationContext()
- BinarySerializer
ClassProvides a basic implementation of the ISerializer interface using a binary format.- BinarySerializer()
ConstructorInitializes a new instance of the BinarySerializer class. - BinarySerializer(BinarySerializationContext)
ConstructorInitializes a new instance of the BinarySerializer class. - BinarySerializer(Predicate<Type>)
ConstructorInitializes a new instance of the BinarySerializer class. - BinarySerializer(Predicate<Type>, BinarySerializationContext)
ConstructorInitializes a new instance of the BinarySerializer class. - Deserialize(Stream)
MethodDeserializes a World instance from the given System.IO.Stream. - Deserialize(Stream, World)
MethodDeserializes Entity instances with their components from the given System.IO.Stream into the given World. - Read<T>(Stream)
MethodRead an object of type T from the given stream. - Read<T>(Stream, BinarySerializationContext)
MethodRead an object of type T from the given stream. - Serialize(Stream, World)
MethodSerializes the given World into the provided System.IO.Stream. - Serialize(Stream, IEnumerable<Entity>)
MethodSerializes the given Entity instances with their components into the provided System.IO.Stream. - Write<T>(Stream, T)
MethodWrites an object of type T on the given stream. - Write<T>(Stream, T, BinarySerializationContext)
MethodWrites an object of type T on the given stream.
- BinarySerializer()
- ISerializerExtension
ClassProvides extension methods to the ISerializer type.- Serialize(this ISerializer, Stream, Entity[])
MethodSerializes the given Entity instances with their components into the provided System.IO.Stream.
- Serialize(this ISerializer, Stream, Entity[])
- TextSerializationContext
ClassRepresents a context used by the TextSerializer to convert types during serialization and deserialization operations.- TextSerializationContext()
ConstructorInitializes a new instance of the TextSerializationContext class. - Dispose()
MethodReleases inner resources. - Marshal<TIn,TOut>(Func<TIn,TOut>)
MethodAdds a convertion between the type TIn and the type TOut during a serialization operation. - Unmarshal<TIn,TOut>(Func<TIn,TOut>)
MethodAdds a convertion between the type TIn and the type TOut during a deserialization operation.
- TextSerializationContext()
- TextSerializer
ClassProvides a basic implementation of the ISerializer interface using a text readable format.- TextSerializer()
ConstructorInitializes a new instance of the TextSerializer class. - TextSerializer(TextSerializationContext)
ConstructorInitializes a new instance of the TextSerializer class. - TextSerializer(Predicate<Type>)
ConstructorInitializes a new instance of the TextSerializer class. - TextSerializer(Predicate<Type>, TextSerializationContext)
ConstructorInitializes a new instance of the TextSerializer class. - Deserialize(Stream)
MethodDeserializes a World instance from the given System.IO.Stream. - Deserialize(Stream, World)
MethodDeserializes Entity instances with their components from the given System.IO.Stream into the given World. - Read<T>(Stream)
MethodRead an object of type T from the given stream. - Read<T>(Stream, TextSerializationContext)
MethodRead an object of type T from the given stream. - Serialize(Stream, World)
MethodSerializes the given World into the provided System.IO.Stream. - Serialize(Stream, IEnumerable<Entity>)
MethodSerializes the given Entity instances with their components into the provided System.IO.Stream. - Write<T>(Stream, T)
MethodWrites an object of type T on the given stream. - Write<T>(Stream, T, TextSerializationContext)
MethodWrites an object of type T on the given stream.
- TextSerializer()
- IComponentReader
InterfaceExposes a method to be called back when getting an Entity components, primarly used for serialization purpose.- OnRead<T>(T, Entity)
MethodProcesses the component of type T.
- OnRead<T>(T, Entity)
- IComponentTypeReader
InterfaceExposes a method to be called back when getting the maximum number of component of a World, primarly used for serialization purpose.- OnRead<T>(int)
MethodProcesses the maximum number of component of type T.
- OnRead<T>(int)
- ISerializer
InterfaceProvides a set of methods to save and load DefaultEcs objects.- Deserialize(Stream)
MethodDeserializes a World instance from the given System.IO.Stream. - Deserialize(Stream, World)
MethodDeserializes Entity instances with their components from the given System.IO.Stream into the given World. - Serialize(Stream, World)
MethodSerializes the given World into the provided System.IO.Stream. - Serialize(Stream, IEnumerable<Entity>)
MethodSerializes the given Entity instances with their components into the provided System.IO.Stream.
- Deserialize(Stream)
The DefaultEcs.System namespace contains types to define workflows of modification on entities and components.
- AComponentSystem<TState,TComponent>
ClassRepresents a base class to process updates on a given World instance to all its components of type TComponent.- AComponentSystem(World)
ConstructorInitialise a new instance of the AComponentSystem<TState,TComponent> class with the given World. - AComponentSystem(World, IParallelRunner)
ConstructorInitialise a new instance of the AComponentSystem<TState,TComponent> class with the given World and IParallelRunner. - AComponentSystem(World, IParallelRunner, int)
ConstructorInitialise a new instance of the AComponentSystem<TState,TComponent> class with the given World and IParallelRunner. - IsEnabled
PropertyGets or sets whether the current AComponentSystem<TState,TComponent> instance should update or not. - World
PropertyGets the World instance on which this system operates. - Dispose()
MethodDoes nothing. - PostUpdate(TState)
MethodPerforms a post-update treatment. - PreUpdate(TState)
MethodPerforms a pre-update treatment. - Update(TState)
MethodUpdates the system once.
Does nothing if IsEnabled is false or if there is no component of type TComponent in the World. - Update(TState, Span<TComponent>)
MethodUpdate the given TComponent once. - Update(TState, TComponent)
MethodUpdate the given TComponent once.
- AComponentSystem(World)
- ActionSystem<T>
ClassRepresents a class to set up easily a custom action as a system update.- ActionSystem(Action<T>)
ConstructorInitialises a new instance of the ActionSystem<T> class with the given System.Action<>. - IsEnabled
PropertyGets or sets whether the current ISystem<T> instance should update or not. - Dispose()
MethodDoes nothing. - Update(T)
MethodUpdates the system once.
Does nothing if IsEnabled is false.
- ActionSystem(Action<T>)
- AEntityMultiMapSystem<TState,TKey>
ClassRepresents a base class to process updates on a given EntityMultiMap<TKey> instance.
Only Get<T>() operations on already present component type are safe.
Any other operation maybe change the inner EntityMultiMap<TKey> and should be done either by setting "useBuffer" of the available constructors to true or using an EntityCommandRecorder.- AEntityMultiMapSystem(EntityMultiMap<TKey>, bool)
ConstructorInitialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given EntityMultiMap<TKey>. - AEntityMultiMapSystem(EntityMultiMap<TKey>, IParallelRunner, int)
ConstructorInitialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given EntityMultiMap<TKey> and IParallelRunner. - AEntityMultiMapSystem(World, bool)
ConstructorInitialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given World.
To create the inner EntityMultiMap<TKey>, WithAttribute and WithoutAttribute attributes will be used. - AEntityMultiMapSystem(World, IParallelRunner, int)
ConstructorInitialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given World.
To create the inner EntityMultiMap<TKey>, WithAttribute and WithoutAttribute attributes will be used. - AEntityMultiMapSystem(World, Func<object,World,EntityMultiMap<TKey>>, bool)
ConstructorInitialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given World.
To create the inner EntityMultiMap<TKey>, WithAttribute and WithoutAttribute attributes will be used. - AEntityMultiMapSystem(World, Func<object,World,EntityMultiMap<TKey>>, IParallelRunner, int)
ConstructorInitialise a new instance of the AEntityMultiMapSystem<TState,TKey> class with the given World and factory.
The current instance will be passed as the first parameter of the factory. - IsEnabled
PropertyGets or sets whether the current AEntityMultiMapSystem<TState,TKey> instance should update or not. - MultiMap
PropertyGets the EntityMultiMap<TKey> instance on which this system operates. - World
PropertyGets the World instance on which this system operates. - Dispose()
MethodDisposes of the inner EntityMultiMap<TKey> instance. - GetKeys()
MethodGets all the TKey of the inner EntityMultiMap<TKey> which Entity instances will be updated. - PostUpdate(TState)
MethodPerforms a post-update treatment. - PostUpdate(TState, TKey)
MethodPerforms a post-update per TKey treatment. - PreUpdate(TState)
MethodPerforms a pre-update treatment. - PreUpdate(TState, TKey)
MethodPerforms a pre-update per TKey treatment. - Update(TState)
MethodUpdates the system once.
Does nothing if IsEnabled is false or if the inner EntityMultiMap<TKey> is empty. - Update(TState, TKey, Entity)
MethodUpdate the given Entity instance once. - Update(TState, TKey, ReadOnlySpan<Entity>)
MethodUpdate the given Entity instances once.
- AEntityMultiMapSystem(EntityMultiMap<TKey>, bool)
- AEntitySetSystem<T>
ClassRepresents a base class to process updates on a given EntitySet instance.
Only Get<T>() operations on already present component type are safe.
Any other operation maybe change the inner EntitySet and should be done either by using setting "useBuffer" of the available constructors to true or using an EntityCommandRecorder.- AEntitySetSystem(EntitySet, bool)
ConstructorInitialise a new instance of the AEntitySetSystem<T> class with the given EntitySet. - AEntitySetSystem(EntitySet, IParallelRunner, int)
ConstructorInitialise a new instance of the AEntitySetSystem<T> class with the given EntitySet and IParallelRunner. - AEntitySetSystem(World, bool)
ConstructorInitialise a new instance of the AEntitySetSystem<T> class with the given World.
To create the inner EntitySet, WithAttribute and WithoutAttribute attributes will be used. - AEntitySetSystem(World, IParallelRunner, int)
ConstructorInitialise a new instance of the AEntitySetSystem<T> class with the given World.
To create the inner EntitySet, WithAttribute and WithoutAttribute attributes will be used. - AEntitySetSystem(World, Func<object,World,EntitySet>, bool)
ConstructorInitialise a new instance of the AEntitySetSystem<T> class with the given World.
To create the inner EntitySet, WithAttribute and WithoutAttribute attributes will be used. - AEntitySetSystem(World, Func<object,World,EntitySet>, IParallelRunner, int)
ConstructorInitialise a new instance of the AEntitySetSystem<T> class with the given World and factory.
The current instance will be passed as the first parameter of the factory. - IsEnabled
PropertyGets or sets whether the current AEntitySetSystem<T> instance should update or not. - Set
PropertyGets the EntitySet instance on which this system operates. - World
PropertyGets the World instance on which this system operates. - Dispose()
MethodDisposes of the inner EntitySet instance. - PostUpdate(T)
MethodPerforms a post-update treatment. - PreUpdate(T)
MethodPerforms a pre-update treatment. - Update(T)
MethodUpdates the system once.
Does nothing if IsEnabled is false or if the inner EntitySet is empty. - Update(T, Entity)
MethodUpdate the given Entity instance once. - Update(T, ReadOnlySpan<Entity>)
MethodUpdate the given Entity instances once.
- AEntitySetSystem(EntitySet, bool)
- AEntitySortedSetSystem<TState,TComponent>
ClassRepresents a base class to process updates on a given EntitySortedSet<TComponent> instance.
Only Get<T>() operations on already present component type are safe.
Any other operation maybe change the inner EntitySortedSet<TComponent> and should be done either by using setting "useBuffer" of the available constructors to true or using an EntityCommandRecorder.- AEntitySortedSetSystem(EntitySortedSet<TComponent>, bool)
ConstructorInitialise a new instance of the AEntitySortedSetSystem<TState,TComponent> class with the given EntitySortedSet<TComponent>. - AEntitySortedSetSystem(World, bool)
ConstructorInitialise a new instance of the AEntitySortedSetSystem<TState,TComponent> class with the given World and factory.
To create the inner EntitySet, WithAttribute and WithoutAttribute attributes will be used. - AEntitySortedSetSystem(World, Func<object,World,EntitySortedSet<TComponent>>, bool)
ConstructorInitialise a new instance of the AEntitySortedSetSystem<TState,TComponent> class with the given World and factory.
To create the inner EntitySet, WithAttribute and WithoutAttribute attributes will be used. - IsEnabled
PropertyGets or sets whether the current AEntitySortedSetSystem<TState,TComponent> instance should update or not. - SortedSet
PropertyGets the EntitySortedSet<TComponent> instance on which this system operates. - World
PropertyGets the World instance on which this system operates. - Dispose()
MethodDisposes of the inner EntitySortedSet<TComponent> instance. - PostUpdate(TState)
MethodPerforms a post-update treatment. - PreUpdate(TState)
MethodPerforms a pre-update treatment. - Update(TState)
MethodUpdates the system once.
Does nothing if IsEnabled is false or if the inner EntitySortedSet<TComponent> is empty. - Update(TState, Entity)
MethodUpdate the given Entity instance once. - Update(TState, ReadOnlySpan<Entity>)
MethodUpdate the given Entity instances once.
- AEntitySortedSetSystem(EntitySortedSet<TComponent>, bool)
- ComponentAttribute
ClassRepresents the base attribute to declare how to build the inner EntitySet of AEntitySetSystem<T> when giving a World instance.
Do not use this attribute, prefer WithAttribute and WithoutAttribute instead.- ComponentAttribute(ComponentFilterType, Type[])
ConstructorInitialize a new instance of the ComponentAttribute type. - ComponentTypes
PropertyThe types of the component. - FilterType
PropertyWhether the component type should be included or excluded.
- ComponentAttribute(ComponentFilterType, Type[])
- DisabledAttribute
ClassMakes so when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance, it will only contain disabled entities. - ParallelSystem<T>
ClassRepresents a collection of ISystem<T> to update in parallel.- ParallelSystem(ISystem<T>, IParallelRunner, ISystem<T>[])
ConstructorInitialises a new instance of the ParallelSystem<T> class. - ParallelSystem(ISystem<T>, IParallelRunner, IEnumerable<ISystem<T>>)
ConstructorInitialises a new instance of the ParallelSystem<T> class. - ParallelSystem(IParallelRunner, ISystem<T>[])
ConstructorInitialises a new instance of the ParallelSystem<T> class. - ParallelSystem(IParallelRunner, IEnumerable<ISystem<T>>)
ConstructorInitialises a new instance of the ParallelSystem<T> class. - IsEnabled
PropertyGets or sets whether the current ParallelSystem<T> instance should update or not. - Dispose()
MethodDisposes all the inner ISystem<T> instances. - Update(T)
MethodUpdates the system once.
- ParallelSystem(ISystem<T>, IParallelRunner, ISystem<T>[])
- SequentialSystem<T>
ClassRepresents a collection of ISystem<T> to update sequentially.- SequentialSystem(ISystem<T>[])
ConstructorInitialises a new instance of the SequentialSystem<T> class. - SequentialSystem(IEnumerable<ISystem<T>>)
ConstructorInitialises a new instance of the SequentialSystem<T> class. - IsEnabled
PropertyGets or sets whether the current SequentialSystem<T> instance should update or not. - Dispose()
MethodDisposes all the inner ISystem<T> instances. - Update(T)
MethodUpdates all the systems once sequentially.
- SequentialSystem(ISystem<T>[])
- WhenAddedAttribute
ClassRepresents a component type to react to its addition when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance.- WhenAddedAttribute(Type[])
ConstructorInitialize a new instance of the WhenAddedAttribute type.
- WhenAddedAttribute(Type[])
- WhenAddedEitherAttribute
ClassRepresents a group of component types to react to at least one of their addition when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance.- WhenAddedEitherAttribute(Type[])
ConstructorInitialize a new instance of the WithEitherAttribute type.
- WhenAddedEitherAttribute(Type[])
- WhenChangedAttribute
ClassRepresents a component type to react to its change when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance.- WhenChangedAttribute(Type[])
ConstructorInitialize a new instance of the WhenChangedAttribute type.
- WhenChangedAttribute(Type[])
- WhenChangedEitherAttribute
ClassRepresents a group of component types to react to at least one of their change when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance.- WhenChangedEitherAttribute(Type[])
ConstructorInitialize a new instance of the WithEitherAttribute type.
- WhenChangedEitherAttribute(Type[])
- WhenRemovedAttribute
ClassRepresents a component type to react to its deletion when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance.- WhenRemovedAttribute(Type[])
ConstructorInitialize a new instance of the WhenRemovedAttribute type.
- WhenRemovedAttribute(Type[])
- WhenRemovedEitherAttribute
ClassRepresents a group of component types to react to at least one of their deletion when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance.- WhenRemovedEitherAttribute(Type[])
ConstructorInitialize a new instance of the WithEitherAttribute type.
- WhenRemovedEitherAttribute(Type[])
- WithAttribute
ClassRepresents a component type to include when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance.- WithAttribute(Type[])
ConstructorInitialize a new instance of the WithAttribute type.
- WithAttribute(Type[])
- WithEitherAttribute
ClassRepresents a group of component types which at least one should be present when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance.- WithEitherAttribute(Type[])
ConstructorInitialize a new instance of the WithEitherAttribute type.
- WithEitherAttribute(Type[])
- WithoutAttribute
ClassRepresents a component type to exclude when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance.- WithoutAttribute(Type[])
ConstructorInitialize a new instance of the WithoutAttribute type.
- WithoutAttribute(Type[])
- WithoutEitherAttribute
ClassRepresents a group of component types which at least one should not be present when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance.- WithoutEitherAttribute(Type[])
ConstructorInitialize a new instance of the WithEitherAttribute type.
- WithoutEitherAttribute(Type[])
- WithPredicateAttribute
ClassMakes so when building the inner EntitySet of AEntitySetSystem<T> when giving a World instance, the decorated method will be used as a component predicate.
The decorated method should be of the type ComponentPredicate<T>(T). - ISystem<T>
InterfaceExposes a method to update a system.- IsEnabled
PropertyGets or sets whether the current ISystem<T> instance should update or not. - Update(T)
MethodUpdates the system once.
Does nothing if IsEnabled is false.
- IsEnabled
- ComponentFilterType
EnumSpecifies which filter rule should be applied when using a ComponentAttribute.- WhenAdded
FieldGiven component types are added. - WhenAddedEither
FieldAt least one of the given component types is added. - WhenChanged
FieldGiven component types are changed. - WhenChangedEither
FieldAt least one of the given component types is changed. - WhenRemoved
FieldGiven component types are removed. - WhenRemovedEither
FieldAt least one of the given component types is removed. - With
FieldGiven component types should be present. - WithEither
FieldAt least one of the given component types should be present. - Without
FieldGiven component type should be absent. - WithoutEither
FieldAt least one of the given component types should not be present.
- WhenAdded
The DefaultEcs.Threading namespace contains types used for multithreading operations.
- DefaultParallelRunner
ClassRepresents an object used to run an IParallelRunnable by using multiple System.Threading.Tasks.Task.- DefaultParallelRunner(int)
ConstructorInitialises a new instance of the DefaultParallelRunner class. - DegreeOfParallelism
PropertyGets the degree of parallelism used to run an IParallelRunnable. - Dispose()
MethodReleases all the resources used by the current DefaultParallelRunner instance. - Run(IParallelRunnable)
MethodRuns the provided IParallelRunnable.
- DefaultParallelRunner(int)
- IParallelRunnable
InterfaceExposes a method to run a process in parallel.- Run(int, int)
MethodRuns the part index out of maxIndex of the process.
- Run(int, int)
- IParallelRunner
InterfaceExposes a method to run in parallel a IParallelRunnable.- DegreeOfParallelism
PropertyGets the degree of parallelism used to run an IParallelRunnable. - Run(IParallelRunnable)
MethodRuns the provided IParallelRunnable.
- DegreeOfParallelism