question: public static void clearImageCacheForMediaEntity ( MediaEntity entity ) { List < MediaFile > mediaFiles = new ArrayList < > ( entity . getMediaFiles ( ) ) ; for ( MediaFile mediaFile : mediaFiles ) { if ( mediaFile . isGraphic ( ) ) { Path file = ImageCache . getCachedFile ( mediaFile . getFileAsPath ( ) ) ; if ( Files . exists ( file ) ) { Utils . deleteFileSafely ( file ) ; } } } }
target:  clear the image cache for all graphics within the given media entity