struct Entitas::SafeAERC

Overview

Automatic Entity Reference Counting (AERC) is used internally to prevent pooling retained entities. If you use retain manually you also have to release it manually at some point. SafeAERC checks if the entity has already been retained or released. It's slower, but you keep the information about the owners.

Defined in:

entitas/aerc.cr

Constructors

Instance Method Summary

Instance methods inherited from struct Entitas::AERC

initialize initialize, release(obj) release, retain(obj) retain, retain_count : Int32 retain_count

Constructor methods inherited from struct Entitas::AERC

new new

Constructor Detail

def self.new(entity : Entitas::Entity) #

[View source]

Instance Method Detail

def includes?(id : UInt64) #

[View source]
def includes?(owner) #

[View source]
def owners : Array(UInt64) #

[View source]
def release(owner) #

[View source]
def retain(owner) #

[View source]
def retain_count : Int32 #

[View source]