Trait rex_instance_pool_trait

Instance Pool Trait.

Direct Known Users

rex_media, rex_media_category, rex_sql_table, rex_structure_element

Indirect Known Users

rex_article, rex_category

Package: redaxo\core
Author: gharlan
Located at redaxo/src/core/lib/base/instance_pool_trait.php

Methods summary

protected static
# addInstance( mixed $key, rex_instance_pool_trait $instance )

Adds an instance.

protected static boolean
# hasInstance( mixed $key )

Checks whether an instance exists for the given key.

protected static null|static
# getInstance( mixed $key, callable $createCallback = null )

Returns the instance for the given key.

public static
# clearInstance( mixed $key )

Removes the instance of the given key.

public static
# clearInstancePool( )

Clears the instance pool.