final class AnnotationsCacheFlusher (View source)

Properties

protected LoggerInterface $logger
protected ConfigurationManager $configurationManager
protected CacheManager $cacheManager
protected ReflectionService $reflectionService

The ReflectionService is only needed during compile time for handling flushConfigurationCachesByCompiledClass

Methods

void
registerAnnotation(string $annotationClassName, array $cacheNames)

Register an annotation that should trigger a cache flush

void
flushConfigurationCachesByCompiledClass(array $classNames)

A slot that flushes caches as needed if classes with specific annotations have changed registerAnnotation()

Details

void registerAnnotation(string $annotationClassName, array $cacheNames)

Register an annotation that should trigger a cache flush

Parameters

string $annotationClassName

fully qualified class name of the annotation

array $cacheNames

Cache names to flush if a class containing the given annotation is compiled (e.g. ["Flow_Mvc_Routing_Route", Flow_Mvc_Routing_Resolve"])

Return Value

void

void flushConfigurationCachesByCompiledClass(array $classNames)

A slot that flushes caches as needed if classes with specific annotations have changed registerAnnotation()

Parameters

array $classNames

The full class names of the classes that got compiled

Return Value

void

Exceptions

NoSuchCacheException