|
ILIAS
trunk Revision v12.0_alpha-413-g215742c0453
|
Multi-Level News Cache Implementation: More...
Collaboration diagram for ILIAS\News\Persistence\NewsCache:Public Member Functions | |
| __construct () | |
| getAggregatedContexts (array $contexts) | |
| Level-1 Cache stores a collection of the aggregated contexts for the provided base context. More... | |
| storeAggregatedContexts (array $contexts, array $aggregated) | |
| invalidateAggregatedContexts (array $contexts) | |
| getUserContextAccess (int $user_id, NewsCriteria $criteria) | |
| Level-2 Cache stores a collection of the base news contexts for a specific user. More... | |
| storeUserContextAccess (int $user_id, NewsCriteria $criteria, array $contexts) | |
| invalidateUserContextAccess (int $user_id) | |
| getNewsForUser (int $user_id, NewsCriteria $criteria) | |
| Level-3 Cache stores a collection of the news items for a specific user. More... | |
| storeNewsForUser (int $user_id, NewsCriteria $criteria, NewsCollection $news) | |
| invalidateNewsForUser (int $user_id, NewsCriteria $criteria) | |
| flush () | |
Protected Member Functions | |
| generateL1Key (string|array $contexts) | |
| generateL3Key (int $user_id, NewsCriteria $criteria) | |
Protected Attributes | |
| readonly bool | $enabled |
| readonly int | $cache_ttl |
| readonly ilCache | $il_cache |
Multi-Level News Cache Implementation:
Definition at line 35 of file NewsCache.php.
| ILIAS\News\Persistence\NewsCache::__construct | ( | ) |
Definition at line 42 of file NewsCache.php.
References ILIAS\Repository\int().
Here is the call graph for this function:| ILIAS\News\Persistence\NewsCache::flush | ( | ) |
Definition at line 224 of file NewsCache.php.
|
protected |
Definition at line 78 of file NewsCache.php.
Referenced by ILIAS\News\Persistence\NewsCache\invalidateAggregatedContexts(), and ILIAS\News\Persistence\NewsCache\storeAggregatedContexts().
Here is the caller graph for this function:
|
protected |
Definition at line 205 of file NewsCache.php.
References $payload, ILIAS\News\Data\NewsCriteria\getMaxPriority(), ILIAS\News\Data\NewsCriteria\getMinPriority(), ILIAS\News\Data\NewsCriteria\getPeriod(), ILIAS\News\Data\NewsCriteria\getStartDate(), and ILIAS\News\Data\NewsCriteria\isNoAutoGenerated().
Referenced by ILIAS\News\Persistence\NewsCache\getNewsForUser(), ILIAS\News\Persistence\NewsCache\invalidateNewsForUser(), and ILIAS\News\Persistence\NewsCache\storeNewsForUser().
Here is the call graph for this function:
Here is the caller graph for this function:| ILIAS\News\Persistence\NewsCache::getAggregatedContexts | ( | array | $contexts | ) |
Level-1 Cache stores a collection of the aggregated contexts for the provided base context.
This method uses a greedy algorithm to collect subset matches in the cache and return both cache hits (as complete NewsContexts objects) and missing contexts.
| NewsContext[] | $contexts |
Definition at line 61 of file NewsCache.php.
References $context, ILIAS\News\Data\NewsContext\denormalize(), and ILIAS\UI\examples\Symbol\Glyph\Sort\sort().
Here is the call graph for this function:| ILIAS\News\Persistence\NewsCache::getNewsForUser | ( | int | $user_id, |
| NewsCriteria | $criteria | ||
| ) |
Level-3 Cache stores a collection of the news items for a specific user.
It returns a LazyNewsCollection or null on cache miss.
Definition at line 172 of file NewsCache.php.
References $payload, $user_id, and ILIAS\News\Persistence\NewsCache\generateL3Key().
Here is the call graph for this function:| ILIAS\News\Persistence\NewsCache::getUserContextAccess | ( | int | $user_id, |
| NewsCriteria | $criteria | ||
| ) |
Level-2 Cache stores a collection of the base news contexts for a specific user.
It returns a list of the NewsContexts (ref_id only) or null on cache miss.
Definition at line 125 of file NewsCache.php.
References $payload, $ref_id, ILIAS\News\Persistence\NewsCache\invalidateUserContextAccess(), and ILIAS\News\Data\NewsCriteria\isOnlyPublic().
Here is the call graph for this function:| ILIAS\News\Persistence\NewsCache::invalidateAggregatedContexts | ( | array | $contexts | ) |
| NewsContext[] | $contexts |
Definition at line 104 of file NewsCache.php.
References $context, ILIAS\News\Persistence\NewsCache\generateL1Key(), and ILIAS\UI\examples\Symbol\Glyph\Sort\sort().
Here is the call graph for this function:| ILIAS\News\Persistence\NewsCache::invalidateNewsForUser | ( | int | $user_id, |
| NewsCriteria | $criteria | ||
| ) |
Definition at line 200 of file NewsCache.php.
References ILIAS\News\Persistence\NewsCache\generateL3Key().
Here is the call graph for this function:| ILIAS\News\Persistence\NewsCache::invalidateUserContextAccess | ( | int | $user_id | ) |
Definition at line 160 of file NewsCache.php.
Referenced by ILIAS\News\Persistence\NewsCache\getUserContextAccess().
Here is the caller graph for this function:| ILIAS\News\Persistence\NewsCache::storeAggregatedContexts | ( | array | $contexts, |
| array | $aggregated | ||
| ) |
| NewsContext[] | $contexts | |
| NewsContext[] | $aggregated |
Definition at line 87 of file NewsCache.php.
References $context, $payload, ILIAS\News\Persistence\NewsCache\generateL1Key(), and ILIAS\UI\examples\Symbol\Glyph\Sort\sort().
Here is the call graph for this function:| ILIAS\News\Persistence\NewsCache::storeNewsForUser | ( | int | $user_id, |
| NewsCriteria | $criteria, | ||
| NewsCollection | $news | ||
| ) |
Definition at line 188 of file NewsCache.php.
References $user_id, ILIAS\News\Persistence\NewsCache\generateL3Key(), and ILIAS\News\Data\NewsCollection\getUserReadStatus().
Here is the call graph for this function:| ILIAS\News\Persistence\NewsCache::storeUserContextAccess | ( | int | $user_id, |
| NewsCriteria | $criteria, | ||
| array | $contexts | ||
| ) |
| NewsContext[] | $contexts |
Definition at line 149 of file NewsCache.php.
References $context, $payload, and ILIAS\News\Data\NewsCriteria\isOnlyPublic().
Here is the call graph for this function:
|
protected |
Definition at line 39 of file NewsCache.php.
|
protected |
Definition at line 37 of file NewsCache.php.
|
protected |
Definition at line 40 of file NewsCache.php.