Package jaxe
Class ImageKeeper
java.lang.Object
jaxe.ImageKeeper
Image loader and cache
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic void
protected Image
Loads an image from a class or returns a cached image from the mapprotected Image
Loads an imagestatic Image
Loads an image from a specific classstatic Image
Loads an image from a specific classstatic Image
Loads an imagestatic Image
Loads an imageprotected void
Removes an image from the mapstatic void
removeImage
(String file) Removes an image out of the cache
-
Field Details
-
_images
Map with images
-
-
Method Details
-
loadImage
Loads an image- Parameters:
file
- Path/filename- Returns:
- Image or
null
-
loadImage
Loads an image- Parameters:
file
- Path/filename- Returns:
- Image or
null
-
loadImage
Loads an image from a specific class- Parameters:
point
- Class to load fromfile
- Path/filename- Returns:
- Image or
null
-
loadImage
Loads an image from a specific class- Parameters:
point
- Class to load fromfile
- Path/filename- Returns:
- Image or
null
-
removeImage
Removes an image out of the cache- Parameters:
file
- Path/filename
-
flushImages
public static void flushImages() -
load
Loads an image- Parameters:
file
- Path/filenamenotNull
- Flag to return a dummy image if image could not be loaded- Returns:
- Image or
null
-
load
Loads an image from a class or returns a cached image from the map- Parameters:
point
- Point to load fromfile
- Path/filenamenotNull
- Flag to return a dummy image if image could not be loaded- Returns:
- Image or
null
-
remove
Removes an image from the map- Parameters:
file
- Pfad/Dateiname
-