Package com.dassault_systemes.catweb.tools.awt |
java.lang.Object
|
+-com.dassault_systemes.catweb.tools.awt.ImageLoader
Framework : PortalBase
Module : PLBtools
public class ImageLoader
The ImageLoader class is a utility class to download Image from file.
Here is an exmaple of use for an image creation and load:
// ---- create the image from a relative file name
Image myImage = ImageLoader.loadImagefromClassRoot("MyImage.gif");
// --- load really myImage
ImageLoader.waitForImage(myImage);
ImageLoader
ImageLoader()
loadImagefromClassRoot
Image loadImagefromClassRoot(String fileName)
Load the image specified by its fileName
- Parameters:
fileName
- - the filename is a relative path to the pathes of the classpath
or codebase path of the application.
- Returns:
the image created.
loadImagefromClass
Image loadImagefromClass(String fileName, Class baseClass)
Load the image specified by its fileName
- Parameters:
fileName
- - the filename is a relative path to path of the class baseClass
- Returns:
the image created.
- See Also:
- java.awt.MediaTracker
waitForImage
void waitForImage(Image image)
Starts loading the image tracked by the default media tracker associated with the ImageLoader.
This method waits until the image has finished loading.
- Parameters:
image
- - the image to load
- See Also:
- java.awt.MediaTracker
waitForImages
void waitForImages(Image[] images)
Starts loading the images tracked by the default media tracker associated with the ImageLoader.
This method waits until the images have finished loading.
- Parameters:
images
- - the images to load
Copyright © 2000, Dassault Systèmes. All rights reserved